aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorWladimir J. van der Laan <laanwj@protonmail.com>2020-10-15 12:00:41 +0200
committerWladimir J. van der Laan <laanwj@protonmail.com>2020-10-15 12:01:11 +0200
commit711ddce94377aea38ce30fa93b3ee8ea1d96ba98 (patch)
treebb4ade34733ca277440adf791a9a2880ec45be51 /src
parent560dea9b26f7f27b851b2d426140a98bd78796fe (diff)
parentfaad92fe1c3cca9795226bd167130976930ddab8 (diff)
Merge #20131: test: Remove unused nVersion=1 in p2p tests
faad92fe1c3cca9795226bd167130976930ddab8 test: Remove unused nVersion=1 in p2p tests (MarcoFalke) Pull request description: After commit ddefb5c0b759950942ac03f28c43b548af7b4033 nVersion is no longer used in p2p logic when sending messages. Only when receiving messages, but in this test no messages are received. ACKs for top commit: laanwj: Code review ACK faad92fe1c3cca9795226bd167130976930ddab8 fanquake: ACK faad92fe1c3cca9795226bd167130976930ddab8 Tree-SHA512: 9a7029187aaa5a7929a4a2199646131ff1ea72df6a855ce7022dd3bb2647dd525356dbc5e460c77007eebcdeab400a689db8cb77e8239af3b539c117a4e0d16e
Diffstat (limited to 'src')
-rw-r--r--src/test/denialofservice_tests.cpp5
1 files changed, 0 insertions, 5 deletions
diff --git a/src/test/denialofservice_tests.cpp b/src/test/denialofservice_tests.cpp
index 712567ac0d..6743dc0070 100644
--- a/src/test/denialofservice_tests.cpp
+++ b/src/test/denialofservice_tests.cpp
@@ -88,7 +88,6 @@ BOOST_AUTO_TEST_CASE(outbound_slow_chain_eviction)
dummyNode1.SetCommonVersion(PROTOCOL_VERSION);
peerLogic->InitializeNode(&dummyNode1);
- dummyNode1.nVersion = 1;
dummyNode1.fSuccessfullyConnected = true;
// This test requires that we have a chain with non-zero work.
@@ -141,7 +140,6 @@ static void AddRandomOutboundPeer(std::vector<CNode *> &vNodes, PeerManager &pee
node.SetCommonVersion(PROTOCOL_VERSION);
peerLogic.InitializeNode(&node);
- node.nVersion = 1;
node.fSuccessfullyConnected = true;
connman->AddNode(node);
@@ -231,7 +229,6 @@ BOOST_AUTO_TEST_CASE(peer_discouragement)
CNode dummyNode1(id++, NODE_NETWORK, 0, INVALID_SOCKET, addr1, 0, 0, CAddress(), "", ConnectionType::INBOUND);
dummyNode1.SetCommonVersion(PROTOCOL_VERSION);
peerLogic->InitializeNode(&dummyNode1);
- dummyNode1.nVersion = 1;
dummyNode1.fSuccessfullyConnected = true;
peerLogic->Misbehaving(dummyNode1.GetId(), DISCOURAGEMENT_THRESHOLD, /* message */ ""); // Should be discouraged
{
@@ -245,7 +242,6 @@ BOOST_AUTO_TEST_CASE(peer_discouragement)
CNode dummyNode2(id++, NODE_NETWORK, 0, INVALID_SOCKET, addr2, 1, 1, CAddress(), "", ConnectionType::INBOUND);
dummyNode2.SetCommonVersion(PROTOCOL_VERSION);
peerLogic->InitializeNode(&dummyNode2);
- dummyNode2.nVersion = 1;
dummyNode2.fSuccessfullyConnected = true;
peerLogic->Misbehaving(dummyNode2.GetId(), DISCOURAGEMENT_THRESHOLD - 1, /* message */ "");
{
@@ -282,7 +278,6 @@ BOOST_AUTO_TEST_CASE(DoS_bantime)
CNode dummyNode(id++, NODE_NETWORK, 0, INVALID_SOCKET, addr, 4, 4, CAddress(), "", ConnectionType::INBOUND);
dummyNode.SetCommonVersion(PROTOCOL_VERSION);
peerLogic->InitializeNode(&dummyNode);
- dummyNode.nVersion = 1;
dummyNode.fSuccessfullyConnected = true;
peerLogic->Misbehaving(dummyNode.GetId(), DISCOURAGEMENT_THRESHOLD, /* message */ "");