File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -32,7 +32,12 @@ def pytest_addoption(parser):
3232 action = "store_true" ,
3333 help = "suppresses error messages about imports that cannot be resolved" ,
3434 )
35-
35+ group .addoption (
36+ "--mypy-config-file" ,
37+ action = "store" ,
38+ type = str ,
39+ help = "adds custom mypy config file" ,
40+ )
3641
3742XDIST_WORKERINPUT_ATTRIBUTE_NAMES = (
3843 "workerinput" ,
@@ -95,7 +100,7 @@ def pytest_configure_node(self, node): # xdist hook
95100 mypy_argv .append ("--ignore-missing-imports" )
96101
97102 if config .getoption ("--mypy-config-file" ):
98- mypy_argv .append ("--config-file" )
103+ mypy_argv .append ("--config-file={}" . format ( config . getoption ( "--mypy-config-file" )) )
99104
100105def pytest_collect_file (path , parent ):
101106 """Create a MypyFileItem for every file mypy should run on."""
You can’t perform that action at this time.
0 commit comments