diff options
author | buck <buck.2019@gmail.com> | 2014-10-15 12:04:05 -0700 |
---|---|---|
committer | buck <buck.2019@gmail.com> | 2014-10-15 12:04:05 -0700 |
commit | a3cb81edd6053a273447ba3821655320ed234a41 (patch) | |
tree | 8a1a84f15ccace44c409d297f7350a4b3f1cb3a7 /tests/test_cmdline.py | |
parent | c2f80902e35e5e4f638d66d1a1996e1ba6dca642 (diff) | |
download | python-coveragepy-git-a3cb81edd6053a273447ba3821655320ed234a41.tar.gz |
make --source and -m play nice together
--HG--
branch : __main__-support
extra : rebase_source : c9ca9fddecafddd5ef4db9cc64ca1c0972130aab
Diffstat (limited to 'tests/test_cmdline.py')
-rw-r--r-- | tests/test_cmdline.py | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/tests/test_cmdline.py b/tests/test_cmdline.py index 695c3bec..3032a2f1 100644 --- a/tests/test_cmdline.py +++ b/tests/test_cmdline.py @@ -33,6 +33,9 @@ class BaseCmdLineTest(CoverageTest): ignore_errors=None, include=None, omit=None, morfs=[], show_missing=None, ) + defaults.start( + main_module=None, + ) defaults.xml_report( ignore_errors=None, include=None, omit=None, morfs=[], outfile=None, ) @@ -472,7 +475,7 @@ class CmdLineTest(BaseCmdLineTest): self.cmd_executes("run -m mymodule", """\ .coverage() .erase() - .start() + .start(main_module='mymodule') .run_python_module('mymodule', ['mymodule']) .stop() .save() @@ -480,7 +483,7 @@ class CmdLineTest(BaseCmdLineTest): self.cmd_executes("run -m mymodule -qq arg1 arg2", """\ .coverage() .erase() - .start() + .start(main_module='mymodule') .run_python_module('mymodule', ['mymodule', '-qq', 'arg1', 'arg2']) .stop() .save() @@ -488,7 +491,7 @@ class CmdLineTest(BaseCmdLineTest): self.cmd_executes("run --branch -m mymodule", """\ .coverage(branch=True) .erase() - .start() + .start(main_module='mymodule') .run_python_module('mymodule', ['mymodule']) .stop() .save() |