Closed chunkyg closed 8 years ago
Please write a regression test so this doesn't break in the future -- I'd suggest an end-to-end test in test/plugins/test_case_time_log_test.py
You're also failing flake8 which means you didn't run the testsuite :(
An integration would actually be easier than what you wrote:
with tempdir() as tmpdir:
tempfile = os.path.join(tempdir, 'tmp.json')
subprocess.check_call((
sys.executable, '-m', 'testify.test_program', '--test-case-results', tempfile, 'test/test_suite_subdir/define_testcase.py'
))
with open(tempfile, 'r') as f:
contents = json.load(f)
T.assert_in('start_time', contents)
T.assert_in('end_time', contents)
or something like that
Let's release this and add the integration test to the followup issue (where we factor out the method param to TestResult)
Fixing a bug, testify stopped reporting/writing test case results(--test-case-results) in its latest version(v0.8.0). This change will fix the issue.