You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently there is no way to read ===Flaky Test Report=== details through any hook or fixture. There is a need to read this test report and write it to different loggers e.g. log files, error files
===Flaky Test Report===
test_example1 passed 1 out of the required 1 times. Success!
test_example2 failed (1 runs remaining out of 2).
<class 'AssertionError'>
assert 0 == 1
+0
-1
[<TracebackEntry /Users/mtarun/tests/test_dummy.py:51>]
test_example2 failed; it passed 0 out of the required 1 times.
<class 'AssertionError'>
assert 0 == 1
+0
-1
[<TracebackEntry /Users/mtarun/tests/test_dummy.py:51>]
===End Flaky Test Report===
The text was updated successfully, but these errors were encountered:
It looks like nose is loading the tests before loading the plugins... so you can monkey patch the code
defpatch_add_flaky_report(self, stream):
""" Patch flaky reporting to also write the output to a file. """original_add_flaky_report(self, stream)
withopen('flaky-report.txt', 'w') asoutput:
original_add_flaky_report(self, output)
original_add_flaky_report=FlakyPlugin._add_flaky_reportFlakyPlugin._add_flaky_report=patch_add_flaky_report
Maybe add a ``--flaky-report-file=path/to/file` configuration
Currently there is no way to read ===Flaky Test Report=== details through any hook or fixture. There is a need to read this test report and write it to different loggers e.g. log files, error files
The text was updated successfully, but these errors were encountered: