aboutsummaryrefslogtreecommitdiff
path: root/src/test/pow_tests.cpp
diff options
context:
space:
mode:
authorDavid Reikher <david.reikher@gmail.com>2019-08-07 14:50:48 +0300
committerDavid Reikher <david.reikher@gmail.com>2019-08-21 08:22:55 +0300
commitb9ee63c71b751fd67da777774ea8c0b27e7db2f8 (patch)
tree9d2cb0d40606aff5108bbd92f1ffd4381b90ad0b /src/test/pow_tests.cpp
parent48e5bfe2240596eb6d2ae64d4daf727fd886a696 (diff)
Make descriptor test deterministic
Changed MaybeUseHInsteadOfApostrophy to UseHInsteadOfApostrophe. This function now always replaces apostrophes with 'h'. The original Check function was renamed to DoCheck and it's called with an additional parameter which tells it to either leave the prv and pub arguments as is or replace the apostrophes with 'h'. The test runs with apostrophes replaced in prv only, pub only, prv and pub and without replacement at all. Replacement of apostrophes in a descriptor and then running DoCheck is conditional on whether apostrophes are found in that descriptor. Additionally, instead of dropping the checksum recalculate it after replacing apostrophes with 'h' in the function UseHInsteadOfApostrophe using the GetDescriptorChecksum function. That way, this also introduces an indirect unit test to GetDescriptoChecksum.
Diffstat (limited to 'src/test/pow_tests.cpp')
0 files changed, 0 insertions, 0 deletions