File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed
pytest-profiling/tests/unit Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change 2
2
# the top-level code in pytest_profiling will be omitted from
3
3
# coverage, so force it to be reloaded within this test unit under coverage
4
4
5
+ import os .path
5
6
from six .moves import reload_module # @UnresolvedImport
6
7
7
8
import pytest_profiling
@@ -69,8 +70,10 @@ def test_writes_summary():
69
70
with patch ("pstats.Stats" , return_value = stats ) as Stats :
70
71
plugin .pytest_sessionfinish (Mock (), Mock ())
71
72
plugin .pytest_terminal_summary (terminalreporter )
73
+ combined = os .path .abspath (
74
+ os .path .join (os .path .curdir , "prof" , "combined.prof" ))
72
75
assert "Profiling" in terminalreporter .write .call_args [0 ][0 ]
73
- assert Stats .called_with ( stats , stream = terminalreporter )
76
+ Stats .assert_called_with ( combined , stream = terminalreporter )
74
77
75
78
76
79
def test_writes_summary_svg ():
You can’t perform that action at this time.
0 commit comments