diff options
author | Amiti Uttarwar <amiti@uttarwar.org> | 2023-02-19 10:09:28 -0700 |
---|---|---|
committer | Amiti Uttarwar <amiti@uttarwar.org> | 2023-03-17 17:59:02 -0700 |
commit | 26c3bf11e2487ed0ac578fb92619c148336003cb (patch) | |
tree | 9e54581d78cc858038a43e9218e5dbf347fa7b4e /src/test/addrman_tests.cpp | |
parent | 48806412e2bcd023b78fc05f6c9ce092360d1db1 (diff) | |
download | bitcoin-26c3bf11e2487ed0ac578fb92619c148336003cb.tar.xz |
scripted-diff: rename local variables to match modern conventions
-BEGIN VERIFY SCRIPT-
sed -i 's/fChanceFactor/chance_factor/g' src/addrman.cpp
sed -i 's/nBucketPos/initial_position/g' src/addrman.cpp
sed -i 's/nBucket/bucket/g' src/addrman.cpp src/addrman_impl.h
sed -i 's/newOnly/new_only/g' src/addrman.cpp src/addrman_impl.h src/addrman.h src/test/addrman_tests.cpp
-END VERIFY SCRIPT-
Co-authored-by: Martin Zumsande <mzumsande@gmail.com>
Diffstat (limited to 'src/test/addrman_tests.cpp')
-rw-r--r-- | src/test/addrman_tests.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/test/addrman_tests.cpp b/src/test/addrman_tests.cpp index 758691cfde..ad59e123d2 100644 --- a/src/test/addrman_tests.cpp +++ b/src/test/addrman_tests.cpp @@ -127,8 +127,8 @@ BOOST_AUTO_TEST_CASE(addrman_ports) // the specified port to tried, but not the other. addrman->Good(CAddress(addr1_port, NODE_NONE)); BOOST_CHECK_EQUAL(addrman->Size(), 2U); - bool newOnly = true; - auto addr_ret3 = addrman->Select(newOnly).first; + bool new_only = true; + auto addr_ret3 = addrman->Select(new_only).first; BOOST_CHECK_EQUAL(addr_ret3.ToStringAddrPort(), "250.1.1.1:8333"); } @@ -144,14 +144,14 @@ BOOST_AUTO_TEST_CASE(addrman_select) BOOST_CHECK(addrman->Add({CAddress(addr1, NODE_NONE)}, source)); BOOST_CHECK_EQUAL(addrman->Size(), 1U); - bool newOnly = true; - auto addr_ret1 = addrman->Select(newOnly).first; + bool new_only = true; + auto addr_ret1 = addrman->Select(new_only).first; BOOST_CHECK_EQUAL(addr_ret1.ToStringAddrPort(), "250.1.1.1:8333"); // Test: move addr to tried, select from new expected nothing returned. BOOST_CHECK(addrman->Good(CAddress(addr1, NODE_NONE))); BOOST_CHECK_EQUAL(addrman->Size(), 1U); - auto addr_ret2 = addrman->Select(newOnly).first; + auto addr_ret2 = addrman->Select(new_only).first; BOOST_CHECK_EQUAL(addr_ret2.ToStringAddrPort(), "[::]:0"); auto addr_ret3 = addrman->Select().first; |