[test] Remove unused code
Zcash: left createArgs() as we still have rpc_wallet_tests which uses it.
This commit is contained in:
parent
d97bfb766b
commit
57be66d30e
|
@ -121,7 +121,6 @@ public:
|
||||||
BOOST_AUTO_TEST_CASE(base58_keys_valid_parse)
|
BOOST_AUTO_TEST_CASE(base58_keys_valid_parse)
|
||||||
{
|
{
|
||||||
UniValue tests = read_json(std::string(json_tests::base58_keys_valid, json_tests::base58_keys_valid + sizeof(json_tests::base58_keys_valid)));
|
UniValue tests = read_json(std::string(json_tests::base58_keys_valid, json_tests::base58_keys_valid + sizeof(json_tests::base58_keys_valid)));
|
||||||
std::vector<unsigned char> result;
|
|
||||||
CBitcoinSecret secret;
|
CBitcoinSecret secret;
|
||||||
CTxDestination destination;
|
CTxDestination destination;
|
||||||
SelectParams(CBaseChainParams::MAIN);
|
SelectParams(CBaseChainParams::MAIN);
|
||||||
|
@ -177,7 +176,6 @@ BOOST_AUTO_TEST_CASE(base58_keys_valid_parse)
|
||||||
BOOST_AUTO_TEST_CASE(base58_keys_valid_gen)
|
BOOST_AUTO_TEST_CASE(base58_keys_valid_gen)
|
||||||
{
|
{
|
||||||
UniValue tests = read_json(std::string(json_tests::base58_keys_valid, json_tests::base58_keys_valid + sizeof(json_tests::base58_keys_valid)));
|
UniValue tests = read_json(std::string(json_tests::base58_keys_valid, json_tests::base58_keys_valid + sizeof(json_tests::base58_keys_valid)));
|
||||||
std::vector<unsigned char> result;
|
|
||||||
|
|
||||||
for (size_t idx = 0; idx < tests.size(); idx++) {
|
for (size_t idx = 0; idx < tests.size(); idx++) {
|
||||||
UniValue test = tests[idx];
|
UniValue test = tests[idx];
|
||||||
|
@ -239,7 +237,6 @@ BOOST_AUTO_TEST_CASE(base58_keys_valid_gen)
|
||||||
BOOST_AUTO_TEST_CASE(base58_keys_invalid)
|
BOOST_AUTO_TEST_CASE(base58_keys_invalid)
|
||||||
{
|
{
|
||||||
UniValue tests = read_json(std::string(json_tests::base58_keys_invalid, json_tests::base58_keys_invalid + sizeof(json_tests::base58_keys_invalid))); // Negative testcases
|
UniValue tests = read_json(std::string(json_tests::base58_keys_invalid, json_tests::base58_keys_invalid + sizeof(json_tests::base58_keys_invalid))); // Negative testcases
|
||||||
std::vector<unsigned char> result;
|
|
||||||
CBitcoinSecret secret;
|
CBitcoinSecret secret;
|
||||||
CTxDestination destination;
|
CTxDestination destination;
|
||||||
|
|
||||||
|
|
|
@ -120,7 +120,6 @@ BOOST_AUTO_TEST_CASE(pmt_malleability)
|
||||||
std::vector<bool> vMatch = boost::assign::list_of(false)(false)(false)(false)(false)(false)(false)(false)(false)(true)(true)(false);
|
std::vector<bool> vMatch = boost::assign::list_of(false)(false)(false)(false)(false)(false)(false)(false)(false)(true)(true)(false);
|
||||||
|
|
||||||
CPartialMerkleTree tree(vTxid, vMatch);
|
CPartialMerkleTree tree(vTxid, vMatch);
|
||||||
std::vector<uint256> vTxid2;
|
|
||||||
BOOST_CHECK(tree.ExtractMatches(vTxid).IsNull());
|
BOOST_CHECK(tree.ExtractMatches(vTxid).IsNull());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -234,11 +234,7 @@ BOOST_AUTO_TEST_CASE(util_IsHex)
|
||||||
|
|
||||||
BOOST_AUTO_TEST_CASE(util_seed_insecure_rand)
|
BOOST_AUTO_TEST_CASE(util_seed_insecure_rand)
|
||||||
{
|
{
|
||||||
int i;
|
|
||||||
int count=0;
|
|
||||||
|
|
||||||
seed_insecure_rand(true);
|
seed_insecure_rand(true);
|
||||||
|
|
||||||
for (int mod=2;mod<11;mod++)
|
for (int mod=2;mod<11;mod++)
|
||||||
{
|
{
|
||||||
int mask = 1;
|
int mask = 1;
|
||||||
|
@ -247,10 +243,9 @@ BOOST_AUTO_TEST_CASE(util_seed_insecure_rand)
|
||||||
//mask is 2^ceil(log2(mod))-1
|
//mask is 2^ceil(log2(mod))-1
|
||||||
while(mask<mod-1)mask=(mask<<1)+1;
|
while(mask<mod-1)mask=(mask<<1)+1;
|
||||||
|
|
||||||
count = 0;
|
int count = 0;
|
||||||
//How often does it get a zero from the uniform range [0,mod)?
|
//How often does it get a zero from the uniform range [0,mod)?
|
||||||
for (i=0;i<10000;i++)
|
for (int i = 0; i < 10000; i++) {
|
||||||
{
|
|
||||||
uint32_t rval;
|
uint32_t rval;
|
||||||
do{
|
do{
|
||||||
rval=insecure_rand()&mask;
|
rval=insecure_rand()&mask;
|
||||||
|
|
Loading…
Reference in New Issue