aboutsummaryrefslogtreecommitdiff
path: root/test/functional/feature_block.py
Commit message (Collapse)AuthorAgeFilesLines
* Pure python ECPieter Wuille2019-06-211-6/+6
| | | | | | | | This removes the dependency on OpenSSL for the interaction tests, by providing a pure-Python toy implementation of secp256k1. Github-Pull: #15826 Rebased-From: 8c7b9324ca3f3ffb178bea56a96ea23f7e0383cb
* Fix missing input template by making minimal txGregory Sanders2019-05-201-14/+0
| | | | | Github-Pull: #15893 Rebased-From: 25b078658139c1aea58393a32ac5a79144d8d140
* Merge #15059: test: Add basic test for BIP34Wladimir J. van der Laan2019-01-081-9/+21
|\ | | | | | | | | | | | | | | | | | | | | | | fab17e8272f5f70213f186809479ee7a75898b1d test: Add basic test for BIP34 (MarcoFalke) Pull request description: BIP34 was disabled for testing, which explains why it had no test. Fix that by enabling it and adding a test. Tree-SHA512: 9cb5702d474117ce6420226eb93ee09d6fb5fc856fabc8b67abe56a088cd727674e0e5462000e1afa83b911374036f90abdbdde56a8c236a75572ed47e10a00f
| * test: Add basic test for BIP34MarcoFalke2018-12-291-9/+21
| |
* | test: Run invalid_txs.InputMissing test in feature_blockMarcoFalke2019-01-051-8/+17
| |
* | Merge #14457: test: add invalid tx templates for use in functional testsWladimir J. van der Laan2019-01-021-12/+54
|\ \ | |/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 59e387705c7e55ec40400301346354fa2d0c613f test: add invalid tx templates for use in functional tests (James O'Beirne) Pull request description: This change adds a list of `CTransaction`-generating templates which each correspond to a specific type of invalid transaction. We then use this list to test for a wider variety of invalid tx types in `p2p_invalid_tx.py` and `feature_block.py`. Consolidating all invalid tx types will allow us to more easily cover all tx reject cases from a variety of tests without repeating ourselves. Validation logic doesn't differ much between mempool and block acceptance, but there *is* a difference and we should be sure we're testing both comprehensively. Right now, I've only added templates covering the tx reject types listed below but if this approach seems worthwhile I will expand the list to be fully comprehensive. ``` bad-txns-in-belowout bad-txns-inputs-duplicate bad-txns-too-many-sigops bad-txns-vin-empty bad-txns-vout-empty bad-txns-vout-negative ``` Tree-SHA512: 05407f4a953fbd7c44c08bb49bb989cefd39a2b05ea00f5b3c92197a3f05e1b302f789e33832445734220e1c333d133aba385740b77b84139b170c583471ce20
| * test: add invalid tx templates for use in functional testsJames O'Beirne2018-11-271-12/+54
| | | | | | | | | | Add templates for easily constructing different kinds of invalid transactions and use them in feature_block and p2p_invalid_tx.
* | test: Bump timeout to run tests in travis thread sanitizerMarcoFalke2018-12-201-3/+3
|/
* qa: Check specific reject reasons in feature_blockMarcoFalke2018-11-131-10/+11
|
* tests: Make feature_block pass on centosMarcoFalke2018-11-091-1/+1
|
* Merge #14007: tests: Run functional test on Windows and enable it on AppveyorMarcoFalke2018-09-241-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 661ac15a4a appveyor: Run functional tests on appveyor (Chun Kuan Lee) 2148c36b6e tests: Make it possible to run functional tests on Windows (Chun Kuan Lee) Pull request description: This PR do the following things: - Make functional tests compatible with Windows - Print color output in functional tests for Windows 10 - Run util and functional tests on appveyor - Do not run symlink tests on Windows Note: - The wallet_multiwallet.py fail is unrelated to the test framework, it's a bug related to c++ code or maybe dependencies. `bitcoind` would exit with 0xC0000005(Access violation) during shutdown occasionally. Disable this for now. - Not using `--failfast` because this is still in experimental. We should track if there is any other error. - Disable ZMQ tests because the python zmq library could cause access violation sometimes. - Disable `feature_notifications` because Bitcoin Core handles the command in different thread, whicha can cause a race condition. Tree-SHA512: b76db137d264e62a5c130e1cbca7a2ca002a7a0f4153fa0b92c1ea6c9c09ef0533e11c49bdbd566c472d8ff59f245758feb5e5a6ec6cb6bb66a1c67bab5fa48a
| * tests: Make it possible to run functional tests on WindowsChun Kuan Lee2018-09-171-1/+1
| |
* | Changed functional tests which do not require wallets to run withoutsanket17292018-09-171-3/+0
|/ | | | | | skipping .Addreses #14216. Changed get_deterministic_priv_key() to a named tuple
* Merge #14180: qa: Run all tests even if wallet is not compiledWladimir J. van der Laan2018-09-131-0/+3
|\ | | | | | | | | | | | | | | | | | | | | fac95398366f644911b58f1605e6bc37fb76782d qa: Run all tests even if wallet is not compiled (MarcoFalke) faa669cbcd1fc799517b523b0f850e01b11bf40a qa: Premine to deterministic address with -disablewallet (MarcoFalke) Pull request description: Currently the test_runner would exit if the wallet was not compiled into the Bitcoin Core executable. However, a lot of the tests run without the wallet just fine and there is no need to globally require the wallet to run the tests. Tree-SHA512: 63177260aa29126fd20f0be217a82b10b62288ab846f96f1cbcc3bd2c52702437703475d91eae3f8d821a3149fc62b725a4c5b2a7b3657b67ffcbc81532a03bb
| * qa: Run all tests even if wallet is not compiledMarcoFalke2018-09-101-0/+3
| |
* | Merge #14119: qa: Read reject reasons from debug log, not p2p messagesWladimir J. van der Laan2018-09-081-40/+40
|\ \ | |/ |/| | | | | | | | | | | | | | | | | | | fac3e22b18cd29053bc17065fd75db7b84ba6f40 qa: Read reject reasons from debug log, not p2p messages (MarcoFalke) Pull request description: For local testing we don't need to rely on p2p messages just to assert a reject reason. Replace reading p2p messages with reading from the debug log file. Tree-SHA512: fa59598ecf5e00cfb420ef1892d90aa415501fd882e1c608894dc577b0d00e93a442326d3a9167fef77d26aafbe345b730b49109982ccad68a5942384564a90b
| * qa: Read reject reasons from debug log, not p2p messagesMarcoFalke2018-08-311-40/+40
| |
* | Fix typos reported by codespellpracticalswift2018-09-041-1/+1
|/
* scripted-diff: Use named arguments in feature_blockMarcoFalke2018-08-291-38/+38
| | | | | | -BEGIN VERIFY SCRIPT- sed -i --regexp-extended -e "s/sync_blocks\((.*?), (True|False), (1.?), /sync_blocks(\1, success=\2, reject_code=\3, reject_reason=/g" ./test/functional/feature_block.py -END VERIFY SCRIPT-
* [Tests] Cleanup feature_block.py, remove unnecessary PreviousSpendableOutput ↵Conor Scott2018-08-091-50/+44
| | | | object
* [Tests] Cleanup extra instances of create_transactionConor Scott2018-08-091-3/+3
|
* Update copyright headers to 2018DrahtBot2018-07-271-1/+1
|
* qa: Avoid start/stop of the network thread mid-testMarcoFalke2018-06-251-3/+1
|
* qa: Pad scriptPubKeys to get minimum sized txsMarcoFalke2018-05-051-1/+2
|
* Merge #13003: qa: Add test for orphan handlingWladimir J. van der Laan2018-04-261-10/+12
|\ | | | | | | | | | | | | | | | | fa02c5b qa: Clarify documentation for send_txs_and_test (MarcoFalke) fadfbd3 qa: Add test for orphan handling (MarcoFalke) Pull request description: Tree-SHA512: e0932d6bd03c73e3113f5457a3ffa3bbfc7b6075dfca8de95224d9df875e60ca6eb15cd8baa226f13de965483006559556191630a83c3bb431e79c53a85ef73f
| * qa: Add test for orphan handlingMarcoFalke2018-04-161-10/+12
| |
* | [tests] Fix feature_block flakinessJohn Newbery2018-04-201-1/+7
|/ | | | | | | | | | | | | | | | | | | feature_block.py occasionally fails on Travis. I believe this is due to a a race condition when reconnecting to bitcoind after a subtest that expects disconnection. If the test runs ahead and sends the INV for the subsequent test before we've received the initial sync getheaders, then we may end up sending two headers messages - one as a response to the initial sync getheaders and one in response to the INV getheaders. If both of those headers fail validation with a DoS score of 50 or higher, then we'll unexpectedly be disconnected. There is only one validation failure that has a DoS score bewteen 50 and 100, which is high-hash. That's why the test is failing immediately after the "Reject a block with invalid work" subtest. Fix is to wait for the initial getheaders from the peer before we start populating our blockstore. That way we won't have any invalid headers to respond to it with.
* [tests] Change feature_block.py to use BitcoinTestFrameworkJohn Newbery2018-03-191-243/+234
|
* [tests] Add logging to feature_block.pyJohn Newbery2018-03-191-19/+58
|
* [tests] Tidy up feature_block.pyJohn Newbery2018-03-191-508/+497
| | | | | | | - move all helper methods to the end - remove block, create_tx and create_and_sign_tx shortcuts - remove --runbarelyexpensive option, since it defaults to True and it's unlikely that anyone ever runs the test with this option set to false.
* [tests] Fix flake8 warnings in feature_block.pyJohn Newbery2018-03-191-100/+109
|
* [tests] Rename feature_* functional tests.Anthony Towns2018-01-251-0/+1293