diff options
| author | Wladimir J. van der Laan <[email protected]> | 2015-03-09 16:04:43 +0100 |
|---|---|---|
| committer | Wladimir J. van der Laan <[email protected]> | 2015-03-09 16:06:14 +0100 |
| commit | 59bd89f11636e90b2d684e8f411d8d7a88622458 (patch) | |
| tree | 8c01545831dd3ba1701f584adacfbc2a6b992a9b /src/test/base58_tests.cpp | |
| parent | tests: change main and wallet tests to BOOST_FIXTURE_TEST_SUITE (diff) | |
| download | discoin-59bd89f11636e90b2d684e8f411d8d7a88622458.tar.xz discoin-59bd89f11636e90b2d684e8f411d8d7a88622458.zip | |
test: Remove UNITTEST params
UNITTEST parameter are not used by any current tests, and the model
(modifyable parameters) is inconvenient when unit-testing. As
they are stored in a global structure eevery test
would have to (re)set up its own parameters.
For consistency it is also better to test with MAIN parameters.
Diffstat (limited to 'src/test/base58_tests.cpp')
| -rw-r--r-- | src/test/base58_tests.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/test/base58_tests.cpp b/src/test/base58_tests.cpp index e7d028188..c242dd26e 100644 --- a/src/test/base58_tests.cpp +++ b/src/test/base58_tests.cpp @@ -127,6 +127,7 @@ BOOST_AUTO_TEST_CASE(base58_keys_valid_parse) std::vector<unsigned char> result; CBitcoinSecret secret; CBitcoinAddress addr; + SelectParams(CBaseChainParams::MAIN); BOOST_FOREACH(Value& tv, tests) { @@ -176,7 +177,6 @@ BOOST_AUTO_TEST_CASE(base58_keys_valid_parse) BOOST_CHECK_MESSAGE(!secret.IsValid(), "IsValid pubkey as privkey:" + strTest); } } - SelectParams(CBaseChainParams::UNITTEST); } // Goal: check that generated keys match test vectors @@ -244,7 +244,7 @@ BOOST_AUTO_TEST_CASE(base58_keys_valid_gen) CTxDestination nodest = CNoDestination(); BOOST_CHECK(!dummyAddr.Set(nodest)); - SelectParams(CBaseChainParams::UNITTEST); + SelectParams(CBaseChainParams::MAIN); } // Goal: check that base58 parsing code is robust against a variety of corrupted data |