Conversation
Codecov Report
@@ Coverage Diff @@
## master #1847 +/- ##
==========================================
+ Coverage 44.22% 44.22% +<.01%
==========================================
Files 83 83
Lines 21539 21538 -1
Branches 5644 5645 +1
==========================================
Hits 9526 9526
+ Misses 10957 10942 -15
- Partials 1056 1070 +14
Continue to review full report at Codecov.
|
mliu49
reviewed
Dec 11, 2019
rmgpy/rmg/mainTest.py
Outdated
| cls.rmg = RMG(input_file=os.path.join(cls.testDir, 'restart_no_filters.py'), | ||
| output_directory=os.path.join(cls.outputDir)) | ||
|
|
||
| cls.rmg.execute() |
Contributor
There was a problem hiding this comment.
I feel like executing the job should be part of the test method rather than in setup.
Member
Author
There was a problem hiding this comment.
I agree. Sorry, I copied from the tests above, but I agree this makes more sense.
38b09c5 to
d50cf62
Compare
The first test restarts the minimal example after ~20 species and includes filters. The second test restarts the super-minimal example after ~9 species and does not include filters.
d50cf62 to
e14e85a
Compare
mliu49
approved these changes
Dec 11, 2019
This was referenced Dec 13, 2019
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation or Problem
See #1846
Description of Changes
This PR address the issue identified in #1846, as well as dealing with a deprecation warnings we were getting from h5py. Finally, this PR adds functional tests that run restart jobs (both with and without filters) to try to catch errors like this in the future.
Testing
The functional tests added should catch the error this PR addresses
Additional note
The functional tests simply check that the restart jobs can complete. A more robust test would be ensure that the same model is achieved, but this would require running a full RMG job, and then restarting from an intermediate seed. For the sake of time in running our tests, this was not implemented.
On my computer, the whole suite of tests in mainTest.py including the new functional tests can run in less than 150 seconds, so I don't think this will drastically increase our testing time.