@@ -41,18 +41,13 @@ def pytest_addoption(parser):
4141def pytest_ignore_collect (path , config ):
4242 has_ro = config .getoption ("--ro-functional" )
4343 has_rw = config .getoption ("--rw-functional" )
44- skip_rest = has_ro or has_rw
4544
4645 base = os .path .basename (str (path ))
4746 is_ro = base == "test_ro_functional.py"
4847 is_rw = base == "test_rw_functional.py"
49- if is_ro or is_rw :
50- if is_ro and not has_ro :
51- return True
52- if is_rw and not has_rw :
53- return True
54- elif skip_rest :
55- config .option .verbose = 2
48+ if is_ro and not has_ro :
49+ return True
50+ if is_rw and not has_rw :
5651 return True
5752
5853
@@ -72,16 +67,15 @@ def pytest_configure(config):
7267 if config .getoption ("--regenerate-output" ):
7368 tests .CLICONFIG .REGENERATE_OUTPUT = config .getoption (
7469 "--regenerate-output" )
75- if not (config .getoption ("--ro-functional" ) or
76- config .getoption ("--rw-functional" )):
77- # Functional tests need access to HOME cached auth.
78- # Unit tests shouldn't be touching any HOME files
79- os .environ ["HOME" ] = os .path .dirname (__file__ ) + "/data/homedir"
8070 if config .getoption ("--only-rest" ):
8171 tests .CLICONFIG .ONLY_REST = True
8272 if config .getoption ("--only-xmlrpc" ):
8373 tests .CLICONFIG .ONLY_XMLRPC = True
8474
75+ if (config .getoption ("--ro-functional" ) or
76+ config .getoption ("--rw-functional" )):
77+ config .option .verbose = 2
78+
8579
8680def pytest_generate_tests (metafunc ):
8781 """
0 commit comments