8000
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cf649b9 commit 534dc92Copy full SHA for 534dc92
tests/test_pytest_mypy.py
@@ -348,6 +348,26 @@ def pytest_configure(config):
348
assert result.ret != 0
349
350
351
+def test_pyproject_toml(testdir, xdist_args):
352
+ """Ensure that the plugin allows configuration with pyproject.toml."""
353
+ testdir.makefile(
354
+ ".toml",
355
+ pyproject="""
356
+ [tool.mypy]
357
+ disallow_untyped_defs = true
358
+ """,
359
+ )
360
+ testdir.makepyfile(
361
+ conftest="""
362
+ def pyfunc(x):
363
+ return x * 2
364
365
366
+ result = testdir.runpytest_subprocess("--mypy", *xdist_args)
367
+ result.stdout.fnmatch_lines(["1: error: Function is missing a type annotation*"])
368
+ assert result.ret != 0
369
+
370
371
def test_setup_cfg(testdir, xdist_args):
372
"""Ensure that the plugin allows configuration with setup.cfg."""
373
testdir.makefile(
0 commit comments