Update unittest with run success check#568
Conversation
|
I blocked this until #573 is resolved. |
…ade/test_for_experiment_success
|
Now this PR adds unittest for #599. Calling |
be86fad to
801ca30
Compare
assertSuccess -> assertComplete
801ca30 to
97a7415
Compare
chriseclectic
left a comment
There was a problem hiding this comment.
The added assert is basically functioning as a way to automatically block for results and check an experiment is Done, so I think the assert name should be changed to reflect that.
It is basically a more opaque that you are just checking:
assertEqual(data.block_for_results().status(), ExperimentStatus.DONE)
Also I think the assertFail test isn't needed and can just be removed, it would be better to be clear in the places where you are looking for errors to assert status = ERROR.
- assertComplete -> assertExperimentDone - remove assertFail - update reno
…ade/test_for_experiment_success
|
Thanks Chris. These all make sense. I updated the PR according to your comments. |
* add run success check * fix readout angle test * update reno Co-authored-by: Christopher J. Wood <cjwood@us.ibm.com>
Summary
When you run
Experiment.runthis will suppress all errors incurred durning the execution and errors will be output as user warningwith stored error traceback. This is problematic behavior in unittest since CI might miss some unexpected bugs as maybe reported in #533.
This PR adds
assertSuccessandassertFailchecks that are expected to be called right after every run method call.Details and comments