aboutsummaryrefslogtreecommitdiff
path: root/qa/rpc-tests
AgeCommit message (Collapse)Author
2017-03-20Rename qa directory to testJohn Newbery
2017-03-17fix logging in nulldummy and proxy_testJohn Newbery
2017-03-17Use log.info() instead of print() in importmulti.pyJohn Newbery
2017-03-17Merge #9818: Save watch only key timestamps when reimporting keysWladimir J. van der Laan
7759aa2 Save watch only key timestamps when reimporting keys (Russell Yanofsky) Tree-SHA512: 433b5a78e5626fb2f3166e6c84c22eabd5239d451dc82694da95af237e034612a24f1a8bc959b7d2f2e576ce0b679be1fa4af929ebfae758c7e832056ab67061
2017-03-15Fix RPC failure testing (2 of 2)John Newbery
Commit 9db8eecac1c713c760c0217b6acb7455c657fa8b improved the assert_raises_jsonrpc() function for better testing of RPC failure modes. This commit completes the job by removing remaining broken try-except RPC testing from the individual test cases and replacing it with calls to assert_raises_jsonrpc().
2017-03-14Test transaction selection when gbt called without segwit supportSuhas Daftuar
2017-03-14Don't require segwit in getblocktemplate for segwit signalling or miningSuhas Daftuar
Segwit's version bit will be signalled for all invocations of CreateNewBlock, and not specifying segwit only will cause CreateNewBlock to skip transactions with witness from being selected.
2017-03-14Merge #9970: Improve readability of segwit.py, smartfees.pyWladimir J. van der Laan
1269b8a Fix logging bug and improve readability of smartfees.py (Suhas Daftuar) b9f34e8 Improve readability of segwit.py (Suhas Daftuar) Tree-SHA512: 2c8ff61678c6c407a95a6530e9bd650ae6bb7c9e52f6dd5f256e19253a1358dd1a7aa33a9639fcb07f443e3a21dae71b9f0865c5f1fcaacb2097a3c6766c7eef
2017-03-14Merge #9977: QA: getblocktemplate_longpoll.py should always use >0 fee txMarcoFalke
655df06 QA: getblocktemplate_longpoll.py should always use >0 fee tx (Suhas Daftuar) Tree-SHA512: 016647ba1408f8aaa3fc954835542354d54bf2391c4252c1c505101edbbe1cf8dd6a07060930109d0341f86360b9391dfef439999a93a5bae68fc901dace0b71
2017-03-13Merge #9830: Add safe flag to listunspent resultWladimir J. van der Laan
dcf2112 Add safe flag to listunspent result (NicolasDorier) af61d9f Add COutput::fSafe member for safe handling of unconfirmed outputs (Russell Yanofsky) Tree-SHA512: 311edb6fa8075b3ede5b24cb8c6e5d133ccd8ac9ecafea07b604ffa812ee4f071337e31695e662d8573590a0460af20aaaeb39d49c9ea87924449ea50bdfb0b3
2017-03-11QA: getblocktemplate_longpoll.py should always use >0 fee txSuhas Daftuar
2017-03-10Fix logging bug and improve readability of smartfees.pySuhas Daftuar
2017-03-10Improve readability of segwit.pySuhas Daftuar
2017-03-10Fix extended rpc tests broken by 8910b4717e5bb946ee6988f7fe9fd461f53a5935John Newbery
2017-03-10Add safe flag to listunspent resultNicolasDorier
2017-03-09Use logging in individual testsJohn Newbery
2017-03-09Use logging in test_framework/comptool.pyJohn Newbery
2017-03-09Use logging in test_framework/blockstore.pyJohn Newbery
2017-03-09Use logging in test_framework/util.pyJohn Newbery
2017-03-09Remove manual debug settings in qa tests.John Newbery
-debug and -logtimemicros are now set by default. Individual test cases no longer need to set these parameters manually.
2017-03-09Always enable debug log and microsecond logging for test nodes.John Newbery
2017-03-09Use logging in mininode.pyJohn Newbery
This commit adds a TestFramework.mininode Logger to the mininode module. This is a child logger of TestFramework, so the handlers set up in test_framework.py will receive records from this logger and emit them to the log file and console as appropriate.
2017-03-09Add logging to p2p-segwit.pyJohn Newbery
2017-03-09Add logging to test_framework.pyJohn Newbery
This commit adds python logging to test_framework.py. By default this will output all log levels (DEBUG-INFO-WARNING-ERROR-CRITICAL) to a test_framework.log file in the temporary test directory, and higher level logs (WARNING-ERROR-CRITICAL) to the console. The level of logging to the console can be controlled by a new log-level parameter. This should have no interaction with the existing trace-rpc parameter.
2017-03-07Return correct error codes in fundrawtransaction().John Newbery
The fundrawtransaction() RPC was returning misleading or incorrect error codes (for example RPC_INTERNAL_ERROR when funding the transaction failed). This commit fixes those error codes: - RPC_INTERNAL_ERROR should not be returned for application-level errors, only for genuine internal errors such as corrupted data. That error code has been replaced with RPC_WALLET_ERROR. This commit also updates the test cases to explicitly test the error code.
2017-03-07Return correct error codes in setban().John Newbery
The setban() RPC was returning misleading or incorrect error codes (for example RPC_CLIENT_NODE_ALREADY_ADDED when an invalid IP address was entered). This commit fixes those error codes: - RPC_CLIENT_INVALID_IP_OR_SUBNET should be returned if the client enters an invalid IP address or subnet. This commit also updates the test cases to explicitly test the error code. This commit also adds a testcase for trying to setban on an invalid subnet.
2017-03-07Return correct error codes in removeprunedfunds().John Newbery
The removeprunedfunds() RPC was returning misleading or incorrect error codes (for example RPC_INTERNAL_ERROR when the transaction was not found in the wallet). This commit fixes those error codes: - RPC_INTERNAL_ERROR should not be returned for application-level errors, only for genuine internal errors such as corrupted data. This error code has been replaced with RPC_WALLET_ERROR. This commit also updates the test cases to explicitly test the error code.
2017-03-07Return correct error codes in blockchain.cpp.John Newbery
RPCs in blockchain.cpp were returning misleading or incorrect error codes (for example getblock() returning RPC_INTERNAL_ERROR when the block had been pruned). This commit fixes those error codes: - RPC_INTERNAL_ERROR should not be returned for application-level errors, only for genuine internal errors such as corrupted data. - RPC_METHOD_NOT_FOUND should not be returned in response to a JSON request for an existing method. Those error codes have been replaced with RPC_MISC_ERROR or RPC_INVALID_PARAMETER as appropriate.
2017-03-07Return correct error codes in bumpfee().John Newbery
The bumpfee() RPC was returning misleading or incorrect error codes (for example RPC_INVALID_ADDRESS_OR_KEY when the transaction was not BIP125 replacable). This commit fixes those error codes: - RPC_INVALID_ADDRESS_OR_KEY if an invalid address was provided: - Invalid change address given - RPC_INVALID_PARAMETER if a single (non-address/key) parameter is incorrect - confTarget and totalFee options should not both be set. - Invalid confTarget - Insufficient totalFee (cannot be less than required fee) - RPC_WALLET_ERROR for any other error - Transaction has descendants in the wallet - Transaction has descendants in the mempool - Transaction has been mined, or is conflicted with a mined transaction - Transaction is not BIP 125 replaceable - Transaction has already been bumped - Transaction contains inputs that don't belong to the wallet - Transaction has multiple change outputs - Transaction does not have a change output - Fee is higher than maxTxFee - New fee rate is less than the minimum fee rate - Change output is too small. This commit also updates the test cases to explicitly test the error code.
2017-03-07Merge #9602: Remove coin age priority and free transactions - implementationWladimir J. van der Laan
b421e6d Update example bitcoin.conf (Alex Morcos) 7d4e950 Allow setting minrelaytxfee to 0 (Alex Morcos) 359e8a0 [cleanup] Remove coin age priority completely. (Alex Morcos) f9b9371 [rpc] Remove priorityDelta from prioritisetransaction (Alex Morcos) 49be7e1 [rpc] Remove priority information from mempool RPC calls (Alex Morcos) 0315888 [test] Remove priority from tests (Alex Morcos) f838005 No longer allow "free" transactions (Alex Morcos) ad727f4 [rpc] sendrawtransaction no longer bypasses minRelayTxFee (Alex Morcos) fe282ac [cleanup] Remove estimatePriority and estimateSmartPriority (Alex Morcos) 400b151 [debug] Change -printpriority option (Alex Morcos) 272b25a [mining] Remove -blockprioritysize. (Alex Morcos) 12839cd [rpc] Remove estimatepriority and estimatesmartpriority. (Alex Morcos) ddf58c7 wallet: Remove sendfree (MarcoFalke) Tree-SHA512: a9a4499405923ce794ef18f9e334dbbd59dfc73a3dc2df6f85cc9c62af6f353ec2eed9c2d5e58e904f918d0d7ab738f403dd4939d9bc2276136864fe63710782
2017-03-06Merge #9929: tests: Delete unused function _rpchost_to_argsWladimir J. van der Laan
99fecf8 tests: Delete unused function _rpchost_to_args (Wladimir J. van der Laan) Tree-SHA512: 40911d048d3fd7b3ce83e9b3caf2a409d55b47cbe08ea4450a16ca72264300bb12d5ef7dbcf335885975119b5977f949e6879546840064138fb506e24494d849
2017-03-06Merge #9843: Fix segwit getblocktemplate testWladimir J. van der Laan
b23dcd2 Fix segwit getblocktemplate test. (John Newbery) Tree-SHA512: db87a99432397bd9aa3b66580a92a69467aa4c8a9e3a191629429f80137a59f6ecb13d129d880ebe404d903e13b153aca3ca99e3b1a94e171a4b8a50fb690f3f
2017-03-06tests: Delete unused function _rpchost_to_argsWladimir J. van der Laan
This function has been unused ever since the RPC tests no longer use `bitcoin-cli`.
2017-03-06Merge #9739: Fix BIP68 activation testWladimir J. van der Laan
f5aba8a Move tx version 2 standardness check to after bip68 activation (John Newbery) 99c0e81 Fix BIP68 activation test (John Newbery) Tree-SHA512: 3633d5359705b33a22cd3d8ea28f41abd93ccc6fe9943c8004f6149add991771df9ea12b4e14192e39e14b414bb5ecc7218e516cfeec97e4c5df29778ac57060
2017-03-06Merge #9832: [qa] assert_start_raises_init_errorWladimir J. van der Laan
025dec0 [qa] assert_start_raises_init_error (NicolasDorier) Tree-SHA512: 0fe3ecbd47625b181aed92f15445ac26993e1a8b9843bbc1088c4adcea774e503b870912a18e13dca3f255c22a9964c1c0ca92c758907538143f316c5272ea4a
2017-03-06[qa] assert_start_raises_init_errorNicolasDorier
2017-03-03[rpc] Remove priorityDelta from prioritisetransactionAlex Morcos
This a breaking API change to the prioritisetransaction RPC call which previously required exactly three arguments and now requires exactly two (hash and feeDelta). The function prioritiseTransaction is also updated.
2017-03-03[test] Remove priority from testsAlex Morcos
Remove all coin age priority functionality from unit tests and RPC tests.
2017-03-03No longer allow "free" transactionsAlex Morcos
Remove -limitfreerelay and always enforce minRelayTxFee in the mempool (except from disconnected blocks) Remove -relaypriority, the option was only used for the ability to allow free transactions to be relayed regardless of their priority. Both notions no longer apply.
2017-03-03Define 7200 second timestamp window constantRussell Yanofsky
2017-03-03Save watch only key timestamps when reimporting keysRussell Yanofsky
Previously if an existing watch only key was reimported with a new timestamp, the new timestamp would not be saved in the key metadata, and would not be used to update the wallet nTimeFirstKey value (which could cause rescanning to start at the wrong point and miss transactions). Issue was pointed out by Jonas Schnelli <dev@jonasschnelli.ch> in https://github.com/bitcoin/bitcoin/pull/9108#issuecomment-279715550
2017-02-27[rpc] sendrawtransaction no longer bypasses minRelayTxFeeAlex Morcos
The prioritisetransaction API can always be used if a transaction needs to be submitted that bypasses minRelayTxFee.
2017-02-27[mining] Remove -blockprioritysize.Alex Morcos
Remove ability of mining code to fill part of a block with transactions sorted by coin age.
2017-02-27Merge #9839: [qa] Make import-rescan.py watchonly check reliableWladimir J. van der Laan
864890a [qa] Make import-rescan.py watchonly check reliable (Russell Yanofsky) Tree-SHA512: ea0e2b1d4fc8f35174c3d575fb751b428daf6ad3aa944fad4e3ddcc9195e4f17051473acabc54203b1d27cca64cf911b737ab92e986c40ef384410652e2dbea1
2017-02-23Fix segwit getblocktemplate test.John Newbery
2017-02-23[qa] Make import-rescan.py watchonly check reliableRussell Yanofsky
Send payments during the test from a different node than the node generating keys to be imported, so the spending node doesn't create transactions that inadvertently involve (spend funds from) the imported keys. Fixes #9826
2017-02-23Merge #9577: Fix docstrings in qa testsMarcoFalke
3f95a80 Fix docstrings in qa tests (John Newbery)
2017-02-23Fix docstrings in qa testsJohn Newbery
This commit fixes the module-level docstrings for the tests and helper modules in qa. Many of these tests were uncommented previously - this commit ensures that every test case has at least a minimum level of commenting.
2017-02-23Merge #9824: qa: Check return code when stopping nodesWladimir J. van der Laan
fa4cd2e qa: Check return code when stopping nodes (MarcoFalke)
2017-02-23qa: Check return code when stopping nodesMarcoFalke
This includes work by jnewbery