New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refactor GenBank tests #3291
Refactor GenBank tests #3291
Conversation
Codecov Report
@@ Coverage Diff @@
## master #3291 +/- ##
=======================================
Coverage 83.98% 83.98%
=======================================
Files 318 318
Lines 51660 51660
=======================================
Hits 43389 43389
Misses 8271 8271 Continue to review full report at Codecov.
|
What do you think @mdehoon? We started with a print-and-compare test, where a string representation the expected parser output was held in a text file. Then in #2124 you refactored to use the unittest framework with the expected parser output as python datatypes. Here it moves the expected output externally again, but into a JSON file. If I was doing this from scratch, I'd probably start with a single file where all the parsed values are verified, supplemented by specific tests of corner cases (e.g. strange line wrapping, value-less qualifiers, atypical line breaks in structured comments, expected warnings from bad locations, bad quotes, ...). (Update: fixed typo) |
I hereby agree to dual licence this and any previous contributions under both
the Biopython License Agreement AND the BSD 3-Clause License.
I have read the
CONTRIBUTING.rst
file, have runpre-commit
locally,and understand that AppVeyor and TravisCI will be used to confirm the Biopython unit
tests and style checks pass with these changes.
I have added my name to the alphabetical contributors listings in the files
NEWS.rst
andCONTRIB.rst
as part of this pull request, am listedalready, or do not wish to be listed. (This acknowledgement is optional.)
Good morning!
I've taken several attempts at refactoring GenBank library, but it is truly a complex task, so I've decided to start from the other end. This commit is focused on moving test data away from the test logic and of course is a subject of a discussion.