@@ -59,37 +59,6 @@ def pytest_addhooks(pluginmanager):
5959 assert res .ret != 0
6060 res .stderr .fnmatch_lines (["*did not find*sys*" ])
6161
62- def test_namespace_early_from_import (self , testdir ):
63- p = testdir .makepyfile (
64- """
65- from pytest import Item
66- from pytest import Item as Item2
67- assert Item is Item2
68- """
69- )
70- result = testdir .runpython (p )
71- assert result .ret == 0
72-
73- @pytest .mark .filterwarnings ("ignore:pytest_namespace is deprecated" )
74- def test_do_ext_namespace (self , testdir ):
75- testdir .makeconftest (
76- """
77- def pytest_namespace():
78- return {'hello': 'world'}
79- """
80- )
81- p = testdir .makepyfile (
82- """
83- from pytest import hello
84- import pytest
85- def test_hello():
86- assert hello == "world"
87- assert 'hello' in pytest.__all__
88- """
89- )
90- reprec = testdir .inline_run (p )
91- reprec .assertoutcome (passed = 1 )
92-
9362 def test_do_option_postinitialize (self , testdir ):
9463 config = testdir .parseconfigure ()
9564 assert not hasattr (config .option , "test123" )
@@ -190,17 +159,6 @@ def pytest_testhook():
190159 assert "deprecated" in warnings [- 1 ]
191160
192161
193- def test_namespace_has_default_and_env_plugins (testdir ):
194- p = testdir .makepyfile (
195- """
196- import pytest
197- pytest.mark
198- """
199- )
200- result = testdir .runpython (p )
201- assert result .ret == 0
202-
203-
204162def test_default_markers (testdir ):
205163 result = testdir .runpytest ("--markers" )
206164 result .stdout .fnmatch_lines (["*tryfirst*first*" , "*trylast*last*" ])
0 commit comments