Starting with pytest 4.0.0, using pytest_namespace to share global variables is deprecated. Now that we are running pytest 4.1, tests fail on:
[INFO] [exec] collecting ... INTERNALERROR> Traceback (most recent call last): [INFO] [exec] INTERNALERROR> File "nuxeo-python-client-master/.eggs/pytest-4.1.1-py2.7.egg/_pytest/main.py", line 203, in wrap_session [INFO] [exec] INTERNALERROR> session.exitstatus = doit(config, session) or 0 [INFO] [exec] INTERNALERROR> File "nuxeo-python-client-master/.eggs/pytest-4.1.1-py2.7.egg/_pytest/main.py", line 242, in _main [INFO] [exec] INTERNALERROR> config.hook.pytest_collection(session=session) [INFO] [exec] INTERNALERROR> File "nuxeo-python-client-master/.eggs/pluggy-0.8.1-py2.7.egg/pluggy/hooks.py", line 284, in __call__ [INFO] [exec] INTERNALERROR> return self._hookexec(self, self.get_hookimpls(), kwargs) [INFO] [exec] INTERNALERROR> File "nuxeo-python-client-master/.eggs/pluggy-0.8.1-py2.7.egg/pluggy/manager.py", line 68, in _hookexec [INFO] [exec] INTERNALERROR> return self._inner_hookexec(hook, methods, kwargs) [INFO] [exec] INTERNALERROR> File "nuxeo-python-client-master/.eggs/pluggy-0.8.1-py2.7.egg/pluggy/manager.py", line 62, in <lambda> [INFO] [exec] INTERNALERROR> firstresult=hook.spec.opts.get("firstresult") if hook.spec else False, [INFO] [exec] INTERNALERROR> File "nuxeo-python-client-master/.eggs/pluggy-0.8.1-py2.7.egg/pluggy/callers.py", line 208, in _multicall [INFO] [exec] INTERNALERROR> return outcome.get_result() [INFO] [exec] INTERNALERROR> File "nuxeo-python-client-master/.eggs/pluggy-0.8.1-py2.7.egg/pluggy/callers.py", line 81, in get_result [INFO] [exec] INTERNALERROR> _reraise(*ex) # noqa [INFO] [exec] INTERNALERROR> File "nuxeo-python-client-master/.eggs/pluggy-0.8.1-py2.7.egg/pluggy/callers.py", line 187, in _multicall [INFO] [exec] INTERNALERROR> res = hook_impl.function(*args) [INFO] [exec] INTERNALERROR> File "nuxeo-python-client-master/.eggs/pytest-4.1.1-py2.7.egg/_pytest/main.py", line 252, in pytest_collection [INFO] [exec] INTERNALERROR> return session.perform_collect() [INFO] [exec] INTERNALERROR> File "nuxeo-python-client-master/.eggs/pytest-4.1.1-py2.7.egg/_pytest/main.py", line 466, in perform_collect [INFO] [exec] INTERNALERROR> self.config.pluginmanager.check_pending() [INFO] [exec] INTERNALERROR> File "nuxeo-python-client-master/.eggs/pluggy-0.8.1-py2.7.egg/pluggy/manager.py", line 251, in check_pending [INFO] [exec] INTERNALERROR> % (name, hookimpl.plugin), [INFO] [exec] INTERNALERROR> PluginValidationError: unknown hook 'pytest_namespace' in plugin <module 'tests.conftest' from 'nuxeo-python-client-master/tests/conftest.py'>
From the commit that removed it:
DEPRECATED: this hook causes direct monkeypatching on pytest, its use is strongly discouraged.
- is related to
-
NXDRIVE-1390 Fix pytest 3.9 warnings that break tests
- Resolved