fname
stringlengths
63
176
rel_fname
stringclasses
706 values
line
int64
-1
4.5k
name
stringlengths
1
81
kind
stringclasses
2 values
category
stringclasses
2 values
info
stringlengths
0
77.9k
⌀
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
55
get_real_func
ref
function
get_real_func(evil)
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
58
test_get_real_func
def
function
def test_get_real_func() -> None: """Check that get_real_func correctly unwraps decorators until reaching the real function""" def decorator(f): @wraps(f) def inner(): pass # pragma: no cover return inner def func(): pass # pragma: no cover wrapped_func ...
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
61
decorator
def
function
def decorator(f): @wraps(f) def inner(): pass # pragma: no cover return inner def func(): pass # pragma: no cover wrapped_func = decorator(decorator(func)) assert get_real_func(wrapped_func) is func wrapped_func2 = decorator(decorator(wrapped_func)) ...
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
63
inner
def
function
def inner(): pass # pragma: no cover return inner def func(): pass # pragma: no cover wrapped_func = decorator(decorator(func)) assert get_real_func(wrapped_func) is func wrapped_func2 = decorator(decorator(wrapped_func)) assert get_real_func(wrapped_func2) ...
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
68
func
def
function
def func(): pass # pragma: no cover wrapped_func = decorator(decorator(func)) assert get_real_func(wrapped_func) is func wrapped_func2 = decorator(decorator(wrapped_func)) assert get_real_func(wrapped_func2) is func # special case for __pytest_wrapped__ attribute: used to obtain the ...
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
71
decorator
ref
function
wrapped_func = decorator(decorator(func))
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
71
decorator
ref
function
wrapped_func = decorator(decorator(func))
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
72
get_real_func
ref
function
assert get_real_func(wrapped_func) is func
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
74
decorator
ref
function
wrapped_func2 = decorator(decorator(wrapped_func))
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
74
decorator
ref
function
wrapped_func2 = decorator(decorator(wrapped_func))
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
75
get_real_func
ref
function
assert get_real_func(wrapped_func2) is func
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
79
_PytestWrapper
ref
function
wrapped_func2.__pytest_wrapped__ = _PytestWrapper(wrapped_func)
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
80
get_real_func
ref
function
assert get_real_func(wrapped_func2) is wrapped_func
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
83
test_get_real_func_partial
def
function
def test_get_real_func_partial() -> None: """Test get_real_func handles partial instances correctly""" def foo(x): return x assert get_real_func(foo) is foo assert get_real_func(partial(foo)) is foo
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
86
foo
def
function
def foo(x): return x assert get_real_func(foo) is foo assert get_real_func(partial(foo)) is foo
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
89
get_real_func
ref
function
assert get_real_func(foo) is foo
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
90
get_real_func
ref
function
assert get_real_func(partial(foo)) is foo
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
93
test_is_generator_asyncio
def
function
def test_is_generator_asyncio(pytester: Pytester) -> None: pytester.makepyfile( """ from _pytest.compat import is_generator import asyncio @asyncio.coroutine def baz(): yield from [1,2,3] def test_is_generator_asyncio(): assert not is_generato...
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
94
makepyfile
ref
function
pytester.makepyfile(
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
108
runpytest_subprocess
ref
function
result = pytester.runpytest_subprocess()
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
109
fnmatch_lines
ref
function
result.stdout.fnmatch_lines(["*1 passed*"])
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
112
test_is_generator_async_syntax
def
function
def test_is_generator_async_syntax(pytester: Pytester) -> None: pytester.makepyfile( """ from _pytest.compat import is_generator def test_is_generator_py35(): async def foo(): await foo() async def bar(): pass assert not i...
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
113
makepyfile
ref
function
pytester.makepyfile(
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
127
runpytest
ref
function
result = pytester.runpytest()
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
128
fnmatch_lines
ref
function
result.stdout.fnmatch_lines(["*1 passed*"])
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
131
test_is_generator_async_gen_syntax
def
function
def test_is_generator_async_gen_syntax(pytester: Pytester) -> None: pytester.makepyfile( """ from _pytest.compat import is_generator def test_is_generator_py36(): async def foo(): yield await foo() async def bar(): yiel...
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
132
makepyfile
ref
function
pytester.makepyfile(
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
147
runpytest
ref
function
result = pytester.runpytest()
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
148
fnmatch_lines
ref
function
result.stdout.fnmatch_lines(["*1 passed*"])
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
151
ErrorsHelper
def
class
raise_baseexception raise_exception raise_fail_outcome
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
153
raise_baseexception
def
function
def raise_baseexception(self): raise BaseException("base exception should be raised") @property def raise_exception(self): raise Exception("exception should be catched") @property def raise_fail_outcome(self): pytest.fail("fail should be catched")
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
157
raise_exception
def
function
def raise_exception(self): raise Exception("exception should be catched") @property def raise_fail_outcome(self): pytest.fail("fail should be catched")
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
161
raise_fail_outcome
def
function
def raise_fail_outcome(self): pytest.fail("fail should be catched")
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
162
fail
ref
function
pytest.fail("fail should be catched")
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
165
test_helper_failures
def
function
def test_helper_failures() -> None: helper = ErrorsHelper() with pytest.raises(Exception): helper.raise_exception with pytest.raises(OutcomeException): helper.raise_fail_outcome
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
166
ErrorsHelper
ref
function
helper = ErrorsHelper()
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
167
raises
ref
function
with pytest.raises(Exception):
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
169
raises
ref
function
with pytest.raises(OutcomeException):
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
173
test_safe_getattr
def
function
def test_safe_getattr() -> None: helper = ErrorsHelper() assert safe_getattr(helper, "raise_exception", "default") == "default" assert safe_getattr(helper, "raise_fail_outcome", "default") == "default" with pytest.raises(BaseException): assert safe_getattr(helper, "raise_baseexception", "default...
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
174
ErrorsHelper
ref
function
helper = ErrorsHelper()
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
175
safe_getattr
ref
function
assert safe_getattr(helper, "raise_exception", "default") == "default"
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
176
safe_getattr
ref
function
assert safe_getattr(helper, "raise_fail_outcome", "default") == "default"
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
177
raises
ref
function
with pytest.raises(BaseException):
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
178
safe_getattr
ref
function
assert safe_getattr(helper, "raise_baseexception", "default")
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
181
test_safe_isclass
def
class
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
182
safe_isclass
ref
class
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
184
CrappyClass
def
class
__class__
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
190
safe_isclass
ref
class
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
190
CrappyClass
ref
class
__class__
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
193
test_cached_property
def
function
def test_cached_property() -> None: ncalls = 0 class Class: @cached_property def prop(self) -> int: nonlocal ncalls ncalls += 1 return ncalls c1 = Class() assert ncalls == 0 assert c1.prop == 1 assert c1.prop == 1 c2 = Class() assert ...
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
196
Class
def
class
prop
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
198
prop
def
function
def prop(self) -> int: nonlocal ncalls ncalls += 1 return ncalls c1 = Class() assert ncalls == 0 assert c1.prop == 1 assert c1.prop == 1 c2 = Class() assert ncalls == 1 assert c2.prop == 2 assert c1.prop == 1
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
203
Class
ref
function
c1 = Class()
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
207
Class
ref
function
c2 = Class()
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
213
test_assert_never_union
def
function
def test_assert_never_union() -> None: x: Union[int, str] = 10 if isinstance(x, int): pass else: with pytest.raises(AssertionError): assert_never(x) # type: ignore[arg-type] if isinstance(x, int): pass elif isinstance(x, str): pass else: ass...
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
219
raises
ref
function
with pytest.raises(AssertionError):
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
220
assert_never
ref
function
assert_never(x) # type: ignore[arg-type]
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
227
assert_never
ref
function
assert_never(x)
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
230
test_assert_never_enum
def
function
def test_assert_never_enum() -> None: E = enum.Enum("E", "a b") x: E = E.a if x is E.a: pass else: with pytest.raises(AssertionError): assert_never(x) # type: ignore[arg-type] if x is E.a: pass elif x is E.b: pass else: assert_never(x) ...
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
237
raises
ref
function
with pytest.raises(AssertionError):
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
238
assert_never
ref
function
assert_never(x) # type: ignore[arg-type]
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
245
assert_never
ref
function
assert_never(x)
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
248
test_assert_never_literal
def
function
def test_assert_never_literal() -> None: x: Literal["a", "b"] = "a" if x == "a": pass else: with pytest.raises(AssertionError): assert_never(x) # type: ignore[arg-type] if x == "a": pass elif x == "b": pass else: assert_never(x)
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
254
raises
ref
function
with pytest.raises(AssertionError):
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
255
assert_never
ref
function
assert_never(x) # type: ignore[arg-type]
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_compat.py
testing/test_compat.py
262
assert_never
ref
function
assert_never(x)
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
33
TestParseIni
def
class
test_getcfg_and_config test_setupcfg_uses_toolpytest_with_pytest test_append_parse_args test_tox_ini_wrong_version test_ini_names test_pyproject_toml test_toxini_before_lower_pytestini test_ini_parse_error test_confcutdir test_invalid_config_options test_silence_unknown_key_warning test_disable_warnings_plugin_disables...
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
34
parametrize
ref
function
@pytest.mark.parametrize(
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
37
test_getcfg_and_config
def
function
def test_getcfg_and_config( self, pytester: Pytester, tmp_path: Path, section: str, filename: str, monkeypatch: MonkeyPatch, ) -> None: sub = tmp_path / "sub" sub.mkdir() monkeypatch.chdir(sub) (tmp_path / filename).write_text( ...
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
59
locate_config
ref
function
_, _, cfg = locate_config([sub])
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
61
parseconfigure
ref
function
config = pytester.parseconfigure(str(sub))
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
64
test_setupcfg_uses_toolpytest_with_pytest
def
function
def test_setupcfg_uses_toolpytest_with_pytest(self, pytester: Pytester) -> None: p1 = pytester.makepyfile("def test(): pass") pytester.makefile( ".cfg", setup=""" [tool:pytest] testpaths=%s [pytest] testpaths=ign...
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
65
makepyfile
ref
function
p1 = pytester.makepyfile("def test(): pass")
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
66
makefile
ref
function
pytester.makefile(
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
76
runpytest
ref
function
result = pytester.runpytest()
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
77
fnmatch_lines
ref
function
result.stdout.fnmatch_lines(["*, configfile: setup.cfg, *", "* 1 passed in *"])
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
80
test_append_parse_args
def
function
def test_append_parse_args( self, pytester: Pytester, tmp_path: Path, monkeypatch: MonkeyPatch ) -> None: monkeypatch.setenv("PYTEST_ADDOPTS", '--color no -rs --tb="short"') tmp_path.joinpath("pytest.ini").write_text( textwrap.dedent( """\ [pyt...
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
83
setenv
ref
function
monkeypatch.setenv("PYTEST_ADDOPTS", '--color no -rs --tb="short"')
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
92
parseconfig
ref
function
config = pytester.parseconfig(tmp_path)
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
98
test_tox_ini_wrong_version
def
function
def test_tox_ini_wrong_version(self, pytester: Pytester) -> None: pytester.makefile( ".ini", tox=""" [pytest] minversion=999.0 """, ) result = pytester.runpytest() assert result.ret != 0 result.stderr.fnmatch_lines( ...
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
99
makefile
ref
function
pytester.makefile(
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
106
runpytest
ref
function
result = pytester.runpytest()
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
108
fnmatch_lines
ref
function
result.stderr.fnmatch_lines(
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
112
parametrize
ref
function
@pytest.mark.parametrize(
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
116
test_ini_names
def
function
def test_ini_names(self, pytester: Pytester, name, section) -> None: pytester.path.joinpath(name).write_text( textwrap.dedent( """ [{section}] minversion = 1.0 """.format( section=section ) ) ...
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
127
parseconfig
ref
function
config = pytester.parseconfig()
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
128
getini
ref
function
assert config.getini("minversion") == "1.0"
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
130
test_pyproject_toml
def
function
def test_pyproject_toml(self, pytester: Pytester) -> None: pytester.makepyprojecttoml( """ [tool.pytest.ini_options] minversion = "1.0" """ ) config = pytester.parseconfig() assert config.getini("minversion") == "1.0" def test_toxini_b...
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
131
makepyprojecttoml
ref
function
pytester.makepyprojecttoml(
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
137
parseconfig
ref
function
config = pytester.parseconfig()
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
138
getini
ref
function
assert config.getini("minversion") == "1.0"
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
140
test_toxini_before_lower_pytestini
def
function
def test_toxini_before_lower_pytestini(self, pytester: Pytester) -> None: sub = pytester.mkdir("sub") sub.joinpath("tox.ini").write_text( textwrap.dedent( """ [pytest] minversion = 2.0 """ ) ) pytester.path.joinp...
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
158
parseconfigure
ref
function
config = pytester.parseconfigure(sub)
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
159
getini
ref
function
assert config.getini("minversion") == "2.0"
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
161
test_ini_parse_error
def
function
def test_ini_parse_error(self, pytester: Pytester) -> None: pytester.path.joinpath("pytest.ini").write_text("addopts = -x") result = pytester.runpytest() assert result.ret != 0 result.stderr.fnmatch_lines(["ERROR: *pytest.ini:1: no section header defined"]) @pytest.mark.xfail(re...
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
163
runpytest
ref
function
result = pytester.runpytest()
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
165
fnmatch_lines
ref
function
result.stderr.fnmatch_lines(["ERROR: *pytest.ini:1: no section header defined"])
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
167
xfail
ref
function
@pytest.mark.xfail(reason="probably not needed")
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
168
test_confcutdir
def
function
def test_confcutdir(self, pytester: Pytester) -> None: sub = pytester.mkdir("sub") os.chdir(sub) pytester.makeini( """ [pytest] addopts = --qwe """ ) result = pytester.inline_run("--confcutdir=.") assert result.ret == 0 ...
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_config.py
testing/test_config.py
171
makeini
ref
function
pytester.makeini(