Commit d7c198c9 authored by Georges Racinet's avatar Georges Racinet 🦑
Browse files

New `--heptapod-hg-native` option

This option makes the functional tests create Mercurial native
projects instead of the default type (currently `hg_git`).

Hence it will be the main tool to validate HGitaly related
developments. Later on, we might want to introduce dedicated
CI jobs. Switching to parametrization can also be considered,
but it wouldn't change so much in CI, because we now have tests

The new flag is stored on the `Heptapod` object, for lack of
better choice in the short term (arguably, that's not a property
of the Heptapod server).
parent 1e662a511408
Pipeline #11394 failed with stages
in 31 minutes and 12 seconds
......@@ -48,6 +48,9 @@ def pytest_addoption(parser):
"direct command nor file system access is possible "
"leading to skipping some tests and some teardown "
"reliability actions.")
parser.addoption('--heptapod-hg-native', action='store_true',
help="Have all Mercurial projects created as 'native' "
"(HGitaly backed)")
help="Root of the group/repository hierarchy. "
"This is mandatory for source installs and ignored "
......@@ -170,6 +173,7 @@ def heptapod(pytestconfig):
# make tests fully independent of current user settings
......@@ -68,6 +68,7 @@ class Heptapod:
chrome_driver_args = ()
def __init__(self, url, ssh_user, ssh_port,
......@@ -75,6 +76,7 @@ class Heptapod:
self.url = url
self.ssh_port = ssh_port
self.ssh_user = ssh_user
self.hg_native = hg_native
self.users = {}
if reverse_call_host is not None:
self.reverse_call_host = reverse_call_host
......@@ -939,6 +939,9 @@ class Project(object):
data['name'] = project_name
url = heptapod.url + '/api/v4/projects'
if heptapod.hg_native:
data.setdefault('vcs_type', 'hg')
def post():
return, headers=headers, data=data)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment