Added missing tests according to Amaury's comments on D885.
Details
Details
- Reviewers
deadalnix - Group Reviewers
Restricted Project - Commits
- rSTAGINGf2feb2421ab1: Added missing test cases for SigHashType
rABCf2feb2421ab1: Added missing test cases for SigHashType
make check
Diff Detail
Diff Detail
- Repository
- rABC Bitcoin ABC
- Branch
- master
- Lint
Lint Passed - Unit
No Test Coverage - Build Status
Buildable 1581 Build 1581: arc lint + arc unit
Event Timeline
src/test/script_sighashtype_tests.cpp | ||
---|---|---|
139 | I think that'd be worth it to serialize and unsupported sighashtype to see it is not botched, as well as some combination of flags. An option would be to just go for (int i = 0; i < 256; i++) { (CDataStream(SER_DISK, 0) << SigHashType(i)) >> unserializedOutput; BOOST_CHECK_EQUAL(unserializedOutput, i); } That's not very subtle, but that do the job :) |
src/test/script_sighashtype_tests.cpp | ||
---|---|---|
139 | Good idea. I did something similar, but tested all flags for every value tested as well. |
src/test/script_sighashtype_tests.cpp | ||
---|---|---|
132 ↗ | (On Diff #2465) | Do not put the comment on the same line as code. |