aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorfanquake <fanquake@gmail.com>2019-11-01 15:29:46 -0400
committerfanquake <fanquake@gmail.com>2019-11-01 15:30:07 -0400
commit3f8d95500db070686bcb552b8dbc61d16c51a5cc (patch)
tree7ec1df4f92c452cd4ac579149a69b480d3d50ff5
parent6a7c40bee403cadedeecd4b1c6528575522094eb (diff)
parent59853c33f1c8781480549effc39baee60ffd837c (diff)
Merge #17345: test: Do not instantiate CAddrDB for static call CAddrDB::Read()
59853c33f1c8781480549effc39baee60ffd837c test: Do not instantiate CAddrDB for static call (Hennadii Stepanov) Pull request description: Ref: https://github.com/bitcoin/bitcoin/blob/6a7c40bee403cadedeecd4b1c6528575522094eb/src/addrdb.h#L84-L94 ACKs for top commit: MarcoFalke: unsigned ACK 59853c33f1c8781480549effc39baee60ffd837c naumenkogs: ACK 59853c3 Tree-SHA512: 06b2e8e4f2b4a4f20454a4828a786878fc2bd441b0ee53f1128a7a0b6ad54dd3ca7598cee000ec60e5e4ef02570a09c01974d2d8260bd11fa9baf16b3ff9ba08
-rw-r--r--src/test/net_tests.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/test/net_tests.cpp b/src/test/net_tests.cpp
index fed65afdbf..f5f217b841 100644
--- a/src/test/net_tests.cpp
+++ b/src/test/net_tests.cpp
@@ -128,9 +128,8 @@ BOOST_AUTO_TEST_CASE(caddrdb_read)
CDataStream ssPeers2 = AddrmanToStream(addrmanUncorrupted);
CAddrMan addrman2;
- CAddrDB adb;
BOOST_CHECK(addrman2.size() == 0);
- BOOST_CHECK(adb.Read(addrman2, ssPeers2));
+ BOOST_CHECK(CAddrDB::Read(addrman2, ssPeers2));
BOOST_CHECK(addrman2.size() == 3);
}
@@ -160,9 +159,8 @@ BOOST_AUTO_TEST_CASE(caddrdb_read_corrupted)
CDataStream ssPeers2 = AddrmanToStream(addrmanCorrupted);
CAddrMan addrman2;
- CAddrDB adb;
BOOST_CHECK(addrman2.size() == 0);
- BOOST_CHECK(!adb.Read(addrman2, ssPeers2));
+ BOOST_CHECK(!CAddrDB::Read(addrman2, ssPeers2));
BOOST_CHECK(addrman2.size() == 0);
}