Page MenuHomePhabricator

[schnorr functional test] remove ComparisonTestFramework dependency
ClosedPublic

Authored by markblundeberg on Jul 8 2019, 22:43.

Details

Summary

This switches the Schnorr test to not rely on comptool (which is
deprecated), and takes advantage of the newly backported P2PDataStore
features. bootstrap_p2p and reconnect_p2p are borrowed from
p2p_invalid_tx.py (introduced D3527).

This nicely removes the need to rely on -whitelist for rejected
blocks, instead we can send them and get "banned" (disconnected), and
then reconnect.

I've also added some logging to the test, while I'm at it.

Test Plan

./test/functional/test_runner.py abc-schnorr.py

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

markblundeberg created this revision.Jul 8 2019, 22:43
Herald added a reviewer: Restricted Project. ยท View Herald TranscriptJul 8 2019, 22:43
Herald added a reviewer: deadalnix. ยท View Herald Transcript

validation_block_tests biting me once again...

markblundeberg planned changes to this revision.Jul 8 2019, 23:00

After seeing this on phabricator it's a much bigger Diff than I imagined ๐Ÿ˜… ... will break it up.

markblundeberg retitled this revision from Rewrite Schnorr functional test to [schnorr functional test] remove ComparisonTestFramework dependency.
markblundeberg edited the summary of this revision. (Show Details)

splitting up the big diff into smaller pieces...

deadalnix accepted this revision.Jul 9 2019, 20:24
deadalnix added inline comments.
test/functional/abc-schnorr.py
2 โ†—(On Diff #10139)

I'm pretty sure bitcoin core did not write that test.

This revision is now accepted and ready to land.Jul 9 2019, 20:24
markblundeberg added inline comments.Jul 9 2019, 21:40
test/functional/abc-schnorr.py
2 โ†—(On Diff #10139)

There is a bunch of borrowed code at this point, in this case stuff from p2p_invalid_tx.py is being added.

I dunno, we aren't very consistent with maintaining copyright headers (in case of backports), in any case ...