Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Tests] Add tests for CAddrMan #902

Merged
merged 3 commits into from Jun 13, 2019

Conversation

@Warrows
Copy link
Collaborator

commented May 19, 2019

Backport of bitcoin#6720 and bitcoin#7212

  • Adds several unittests for CAddrMan and CAddrInfo.
  • Makes small modifications to CAddrMan to allow deterministic and targeted tests.
  • Increases the accuracy of CAddrMan tests.
  • Removes non-determinism in tests by overriding the random number generator.
  • Extracts testing code from addrman class to test class.

One more step for #799.

@Warrows Warrows added the Tests label May 19, 2019

@Warrows Warrows self-assigned this May 19, 2019

@Warrows Warrows added this to Later in perpetual updating PIVX Core to BTC Core via automation May 19, 2019

@Warrows Warrows changed the title 2019 bitcoin bp 6720 [Tests] Add tests for CAddrMan May 19, 2019

@Warrows Warrows referenced this pull request May 19, 2019

Open

Bring PIVX random on par with bitcoin #799

4 of 48 tasks complete

@Warrows Warrows added the Network label May 19, 2019

@Fuzzbawls Fuzzbawls added the Upstream label May 20, 2019

@Fuzzbawls
Copy link
Collaborator

left a comment

overall utACK, with some stylistic changes needed.

Show resolved Hide resolved src/test/addrman_tests.cpp Outdated
Show resolved Hide resolved src/test/addrman_tests.cpp Outdated
Show resolved Hide resolved src/test/addrman_tests.cpp Outdated
Show resolved Hide resolved src/test/addrman_tests.cpp Outdated
Show resolved Hide resolved src/test/addrman_tests.cpp Outdated

EthanHeilman and others added some commits Sep 22, 2015

Creates unittests for addrman, makes addrman testable.
Adds several unittests for addrman to verify it works as expected.
Makes small modifications to addrman to allow deterministic and targeted tests.
Increase test coverage for addrman and addrinfo
Adds several unittests for CAddrMan and CAddrInfo.
Increases the accuracy of addrman tests.
Removes non-determinism in tests by overriding the random number generator.
Extracts testing code from addrman class to test class.

@Warrows Warrows force-pushed the Warrows:2019_bitcoin-bp_6720 branch from b1add18 to c84e0e8 May 27, 2019

@Warrows Warrows closed this May 27, 2019

@Warrows Warrows reopened this May 27, 2019

@Fuzzbawls Fuzzbawls added this to the 3.3.0 milestone May 28, 2019

@Mrs-X

Mrs-X approved these changes Jun 3, 2019

Copy link
Collaborator

left a comment

utACK

@Fuzzbawls

This comment has been minimized.

Copy link
Collaborator

commented Jun 13, 2019

ACK c84e0e8

@Fuzzbawls Fuzzbawls merged commit c84e0e8 into PIVX-Project:master Jun 13, 2019

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details

perpetual updating PIVX Core to BTC Core automation moved this from Later to Done Jun 13, 2019

Fuzzbawls added a commit that referenced this pull request Jun 13, 2019

Merge #902: [Tests] Add tests for CAddrMan
c84e0e8 [Code Style] Remove std namespace in test file (warrows)
3355c86 Increase test coverage for addrman and addrinfo (Ethan Heilman)
d4da015 Creates unittests for addrman, makes addrman testable. (EthanHeilman)

Tree-SHA512: cd960109d8f3bdc46dfd58da2136a748aa8ecb1b3bacfa031af0a1544bd90514fe71b8fc63650e61c5872c7a42febc986616252550a71c510bdc7f9e1ab87e0f

@Warrows Warrows deleted the Warrows:2019_bitcoin-bp_6720 branch Jun 16, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.