Skip to content
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

secp256k1: Rework DER sig parsing tests. #2109

Merged
merged 1 commit into from
Feb 22, 2020

Conversation

davecgh
Copy link
Member

@davecgh davecgh commented Feb 21, 2020

This requires #2106.

This reworks the DER signature parsing tests to ensure 100% test coverage of all branches in the parsing code and also test for the explicit reason for a failure to ensure that each test is actually testing the intended condition.

Compare this to the previous more generic validity testing which only tested that a signature failed to parse as opposed to why it failed to parse. The result was that some of the tests were not actually testing what they claimed.

@davecgh davecgh added this to the 1.6.0 milestone Feb 21, 2020
@dajohi
Copy link
Member

dajohi commented Feb 21, 2020

go.mod needs a 1.13 bump

@davecgh davecgh force-pushed the secp256k1_der_sig_parsing_tests branch from 90705b9 to 4aef3f3 Compare February 21, 2020 22:15
@davecgh
Copy link
Member Author

davecgh commented Feb 21, 2020

@dajohi Good call. Done.

This reworks the DER signature parsing tests to ensure 100% test
coverage of all branches in the parsing code and also test for the
explicit reason for a failure to ensure that each test is actually
testing the intended condition.

Compare this to the previous more generic validity testing which only
tested that a signature failed to parse as opposed to _why_ it failed to
parse.  The result was that some of the tests were not actually testing
what they claimed.
@davecgh davecgh force-pushed the secp256k1_der_sig_parsing_tests branch from 4aef3f3 to b10c942 Compare February 22, 2020 00:13
@davecgh davecgh merged commit b10c942 into decred:master Feb 22, 2020
@davecgh davecgh deleted the secp256k1_der_sig_parsing_tests branch February 22, 2020 00:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants