forked from jupyter-server/enterprise_gateway
-
Notifications
You must be signed in to change notification settings - Fork 0
/
conftest.py
17 lines (13 loc) · 792 Bytes
/
conftest.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
def pytest_addoption(parser):
parser.addoption("--host", action="store", default="localhost:8888")
parser.addoption("--username", action="store", default="elyra")
parser.addoption("--impersonation", action="store", default="false")
def pytest_generate_tests(metafunc):
# This is called for every test. Only get/set command line arguments
# if the argument is specified in the list of test "fixturenames".
if 'host' in metafunc.fixturenames:
metafunc.parametrize("host", [metafunc.config.option.host])
if 'username' in metafunc.fixturenames:
metafunc.parametrize("username", [metafunc.config.option.username])
if 'impersonation' in metafunc.fixturenames:
metafunc.parametrize("impersonation", [metafunc.config.option.impersonation])