aboutsummaryrefslogtreecommitdiff
path: root/qa
AgeCommit message (Collapse)Author
2016-12-02[qa] Test getblocktemplate default_witness_commitmentSuhas Daftuar
Github-Pull: #9189 Rebased-From: 95f4a03777ec2ad82a94a3e2890192a93ad83509
2016-11-20Modify getblocktxn handler not to drop requests for old blocksRussell Yanofsky
The current getblocktxn implementation drops and ignores requests for old blocks, which causes occasional sync_block timeouts during the p2p-compactblocks.py test as reported in https://github.com/bitcoin/bitcoin/issues/8842. The p2p-compactblocks.py test setup creates many new blocks in a short period of time, which can lead to getblocktxn requests for blocks below the hardcoded depth limit of 10 blocks. This commit changes the getblocktxn handler not to ignore these requests, so the peer nodes in the test setup will reliably be able to sync. The protocol change is documented in BIP-152 update "Allow block responses to getblocktxn requests" at https://github.com/bitcoin/bips/pull/469. The protocol change is not expected to affect nodes running outside the test environment, because there shouldn't normally be lots of new blocks being rapidly added that need to be synced. Github-Pull: #9058 Rebased-From: dac53b58b555183ccc0d5e64c428528267cd98b3 Github-Pull: #9160 Rebased-From: ec34648766c4052816e4072cc61ad429430bcfd9
2016-11-20Align constant names for maximum compact block / blocktxn depthPieter Wuille
Github-Pull: #8637 Rebased-From: 3ac6de0a045cc9b2047ceb19af970e7ffbf905fa
2016-11-20More agressively filter compact block requestsMatt Corallo
Unit test adaptations by Pieter Wuille. Github-Pull: #8637 Rebased-From: fe998e962dc015978f104b782afb7daec3c4d4df
2016-11-19[qa] Fix stale data bug in test_compactblocks_not_at_tipRussell Yanofsky
Clear test_node.last_block before requesting blocks in the compactblocks_not_at_tip test so comparisons won't fail if a blocks were received before the test started. The bug doesn't currently cause any problems due to the order tests run, but this will change in the next commit. Github-Pull: #9058 Rebased-From: 55bfddcabbf9e8a3743f77167ba4a43aaba9f948
2016-11-19[qa] Fix bug in compactblocks v2 mergeRussell Yanofsky
Bug caused the wait_for_block_announcement to be called on the wrong node, leading to nondeterminism and occasional test failures. Bug was introduced in merge commit: d075479 Merge #8882: [qa] Fix race conditions in p2p-compactblocks.py and sendheaders.py Underlying commits which conflicted were: 27acfc1 [qa] Update p2p-compactblocks.py for compactblocks v2 6976db2 [qa] Another attempt to fix race condition in p2p-compactblocks.py The first commit changed the test_compactblock_construction function signature and second commit added code which wasn't updated during the merge to use the new arguments. Suhas Daftuar <sdaftuar@chaincode.com> noticed the bug and suggested the fix. Github-Pull: #9058 Rebased-From: 47e9659ecfbe07077a4564591095bd5510e0f917
2016-11-19[qa] Wait for specific block announcement in p2p-compactblocksRussell Yanofsky
Change check_announcement_of_new_block() to wait specifically for the announcement of the newly created block, instead of waiting for any announcement at all. A difficult to reproduce failure in check_announcement_of_new_block() that happened in a travis build (https://travis-ci.org/bitcoin/bitcoin/jobs/175198367) might have happened because an older announcement was mistaken for the expected one. The error looked like: Assertion failed: Failed File ".../bitcoin/qa/rpc-tests/test_framework/test_framework.py", line 145, in main self.run_test() File ".../bitcoin/build/../qa/rpc-tests/p2p-compactblocks.py", line 787, in run_test self.test_sendcmpct(self.nodes[1], self.segwit_node, 2, old_node=self.old_node) File ".../bitcoin/build/../qa/rpc-tests/p2p-compactblocks.py", line 201, in test_sendcmpct check_announcement_of_new_block(node, test_node, lambda p: p.last_cmpctblock is None and p.last_inv is not None) File ".../bitcoin/build/../qa/rpc-tests/p2p-compactblocks.py", line 194, in check_announcement_of_new_block assert(predicate(peer)) This commit also changes the assertion failed message above to include more detailed information for debug. Github-Pull: #9159 Rebased-From: dfa44d1b07a6d1022005dba63dd6372739eee8a0
2016-11-19[qa] Add more helpful RPC timeout messageRussell Yanofsky
Replace previous timeout('timed out',) exception with more detailed error. Github-Pull: #9077 Rebased-From: e89614b6abf28d7fe201c3db44a0df6e4db6de03
2016-11-19[qa] Increase wallet-dump RPC timeoutRussell Yanofsky
Increase wallet-dump RPC timeout from 30 seconds to 1 minute. This avoids a timeout error that seemed to happen regularly (around 50% of builds) on a particular jenkins server during the first getnewaddress RPC call made by the test. The failing stack trace looked like: Unexpected exception caught during testing: timeout('timed out',) File ".../bitcoin/qa/rpc-tests/test_framework/test_framework.py", line 146, in main self.run_test() File ".../bitcoin/qa/rpc-tests/wallet-dump.py", line 73, in run_test addr = self.nodes[0].getnewaddress() File ".../bitcoin/qa/rpc-tests/test_framework/coverage.py", line 49, in __call__ return_val = self.auth_service_proxy_instance.__call__(*args, **kwargs) File ".../bitcoin/qa/rpc-tests/test_framework/authproxy.py", line 145, in __call__ response = self._request('POST', self.__url.path, postdata.encode('utf-8')) File ".../bitcoin/qa/rpc-tests/test_framework/authproxy.py", line 121, in _request return self._get_response() File ".../bitcoin/qa/rpc-tests/test_framework/authproxy.py", line 160, in _get_response http_response = self.__conn.getresponse() File "/usr/lib/python3.4/http/client.py", line 1171, in getresponse response.begin() File "/usr/lib/python3.4/http/client.py", line 351, in begin version, status, reason = self._read_status() File "/usr/lib/python3.4/http/client.py", line 313, in _read_status line = str(self.fp.readline(_MAXLINE + 1), "iso-8859-1") File "/usr/lib/python3.4/socket.py", line 374, in readinto return self._sock.recv_into(b) Github-Pull: #9077 Rebased-From: 8463aaa63c5ac76421c4d2754ea9e17a31584c93
2016-11-19[qa] add assert_raises_message to check specific error messagemrbandrews
Github-Pull: #9168 Rebased-From: 307acdd3df03082295ac0f7fe9eba7dd35973bc4
2016-10-31[qa] Test that invalid compactblocks don't result in banSuhas Daftuar
2016-10-17remove redundant tests in p2p-segwit.pyJohnson Lau
Github-Pull: #8499 Rebased-From: 67d6ee1e3679504f46473fe0818970565ff3b137
2016-10-17test segwit uncompressed key fixesJohnson Lau
Github-Pull: #8499 Rebased-From: 9260085377e89e666d0cb95b462261d7e3a9c82f
2016-10-17[qa] Add tests for uncompressed pubkeys in segwitSuhas Daftuar
Github-Pull: #8499 Rebased-From: b811124202152424109b8e95ebe7ac25ff2e83c0
2016-10-17Make test framework produce lowS signaturesJohnson Lau
Github-Pull: #8499 Rebased-From: 9f0397aff7afa2afa9328daea0a2053122e79d44
2016-10-17Add standard limits for P2WSH with testsJohnson Lau
Github-Pull: #8499 Rebased-From: 3ade2f64cfe43ab53e4869ffc35d5fd23201e1c1
2016-10-17[qa] Build v4 blocks in p2p-compactblocktestsMatt Corallo
This fixes an issue in backporting to 0.13 as 0.13 enforces SF activation by block version lockin instead of through a hard-coded block height. Github-Pull: #8916 Rebased-From: a4ad37d4ef4bcd81bc9d867b277efdebc86bc2e8
2016-10-17[qa] Send segwit-encoded blocktxn messages in p2p-compactblocksMatt Corallo
Github-Pull: #8916 Rebased-From: 032e883b937a6b70d5c367fc2ee57d7eea8cb473
2016-10-13[qa] Fix compact block shortids for a test caseDagur Valberg Johannsson
Github-Pull: #8904 Rebased-From: 4cdece40419bcc97345357f9268e03b0aff400b5
2016-10-13Fix overly-prescriptive p2p-segwit test for new fetch logicMatt Corallo
Github-Pull: #8393 Rebased-From: be7555f0c03057bb5537cc42ca9d4937389f0670
2016-10-13[qa] Fix bug in mininode witness deserializationSuhas Daftuar
Also improve tx printing Github-Pull: #8393 Rebased-From: f5b9b8f437c040205896ad0d7a6656efa08b5601
2016-10-13[qa] Add support for compactblocks v2 to mininodeSuhas Daftuar
Github-Pull: #8393 Rebased-From: 422fac649f75c907cad6ab7e2768b9032b9eae42
2016-10-13[qa] Update p2p-compactblocks.py for compactblocks v2Suhas Daftuar
Github-Pull: #8393 Rebased-From: 27acfc1d2ee53cc52b54befd2d4bfa24a77a2eef
2016-10-06[qa] Fix race condition in sendheaders.pySuhas Daftuar
Also de-duplicates code that has been moved to mininode Github-Pull: #8882 Rebased-From: b55d9411e7e1aa36ddabba3b942f2e1c736c1bd9
2016-10-05[qa] Another attempt to fix race condition in p2p-compactblocks.pySuhas Daftuar
sync_with_ping() only guarantees that the node has processed messages it's received from the peer, not that block announcements from the node have made it back to the peer. Replace sync_with_ping() with an explicit check that the node's tip has been announced. Github-Pull: #8882 Rebased-From: 6976db2f4687d575e1b4bee5aaf1d93a794f23c3
2016-10-03test: Explicitly set encoding to utf8 when opening text filesWladimir J. van der Laan
These are text files but their encoding does not depend on the locale. Not all of them require utf8 but it is better to fix it at something to remove potential unpredictability. This is necessary on FreeBSD where no locale is set by default, and apparently Python defaults not only the terminal encoding to the locale but that of every text file. So without LOCALE environment it defaults text file encoding to ASCII. This causes problems with e.g. `bitcoin.conf`. Luckily the locale doesn't affect the default encoding for str.encode() and bytes.decode() on Python 3, so this is the only change necessary. Github-Pull: #8840 Rebased-From: 30930e847e2483c7c8163cc581b392bc288250e9
2016-10-03[qa] util: Move wait_bitcoinds() into stop_nodes()MarcoFalke
Github-Pull: #8860 Rebased-From: fa7c35c4ec630838178b4674288da33561a66f08
2016-10-03[qa] Add getinfo smoke tests and rework versionbits testMarcoFalke
Github-Pull: #8780 Rebased-From: fa6e71b27d00766897f3e69775d450924a58a153
2016-10-03[qa] mininode: Only allow named args in wait_untilMarcoFalke
Github-Pull: #8857 Rebased-From: fa666094cf5b9ac4a7c1732a7ffa001afffcd938
2016-10-03[qa] Fix race condition in p2p-compactblocks testSuhas Daftuar
Also fix a bug in the sync_with_ping() helper function Github-Pull: #8854 Rebased-From: b5fd666984fdb7125cb809c773b36034f32128cc
2016-10-03Fix nulldummy.py testJohnson Lau
Github-Pull: #8841 Rebased-From: 46a4774d2bb9cc863e43507212ef989fa10d56d4
2016-10-03test: Avoid ConnectionResetErrors during RPC testsWladimir J. van der Laan
This is necessary on FreeBSD and MacOSX, at least. See https://github.com/bitcoin/bitcoin/pull/8834#issuecomment-250450213 Github-Pull: #8839 Rebased-From: 1d28faf9e94fcf240ece7336d61ec297b064bc37
2016-10-03[qa] nulldummy: Don't run unused codeMarcoFalke
Github-Pull: #8835 Rebased-From: fa156c604e7d86d84f7731b05d7530bc91d2736b
2016-10-03[qa] blockstore: Switch to dumb dbmMarcoFalke
Github-Pull: #8834 Rebased-From: fa9cd25ed0587078e3218965606c79ebf8138d53
2016-10-03[qa] Split up slow RPC calls to avoid pruning test timeoutsSuhas Daftuar
Github-Pull: #8827 Rebased-From: a0f8482f3e9b07e37c3f1b6fa09683b448810955
2016-10-03Ping regularly in p2p-segwit.py to keep connection aliveJohnson Lau
This pings regularly while building a big block in p2p-segwit.py, to prevent timeout Github-Pull: #8803 Rebased-From: 0637b02fce04c800acc6747687c91c9b22f642e5
2016-09-26Implement NULLDUMMY softforkJohnson Lau
Github-Pull: #8636 Rebased-From: 482f852da65457eb2fbea6b259e7568133fb81c4
2016-09-26Fix broken sendcmpct test in p2p-compactblocks.pySuhas Daftuar
Python lambda use was incorrect. sendcmpct messages need to be synchronized with RPC calls to generate(). Headers need to be synced (eg with getheaders) for cmpctblock announcements to start. Last test omitted sending a sendcmpct message. Github-Pull: #8739 Rebased-From: 157254a4bfdfc4ca3ad5bf2d84e82f290bd0c7f2)
2016-09-26Add p2p test for BIP 152 (compact blocks)Suhas Daftuar
Github-Pull: #8418 Rebased-From: 45c7ddd109465e03551f5b39c2e650c243b4a078
2016-09-26Add support for compactblocks to mininodeSuhas Daftuar
Github-Pull: #8418 Rebased-From: 9a22a6c0891256f02f4906c1c13fb22a9722ec7c
2016-09-26Tests: refactor compact size serialization in mininodeSuhas Daftuar
Github-Pull: #8418 Rebased-From: a8689fdf8e10300b73750161a73a23467ecd1efe
2016-09-26Implement SipHash in PythonPieter Wuille
Github-Pull: #8418 Rebased-From: 9c8593d2b4e25ef628172ceadbedf0ef078d01ef
2016-09-26Add basic test for IsStandard witness transaction blindinginstagibbs
Github-Pull: #8525 Rebased-From: ca10a03addf70421893791c2c499e82fc494d60b
2016-09-21[copyright] Add missing copyright headersisle2983
Github-Pull: #8676 Rebased-From: 783e930e68a312bc7654d833053cceead18dd688
2016-09-21[qa] wallet: Check legacy wallet as wellMarcoFalke
Github-Pull: #8716 Rebased-From: fa644d0053ca40740b9e7b8982ff6c5d5640e4af
2016-09-21[qa] walletbackup: Sync blocks inside the loopMarcoFalke
Github-Pull: #8724 Rebased-From: fad41f308f5e0e0650e3eed96c8c8575b3f7c33e
2016-09-21[doc] - clarify statement about parallel jobs in rpc-tests.pyisle2983
Github-Pull: #8625 Rebased-From: 14675610245e951f2b922a0eaad6eb7d011ae87e
2016-09-21[qa] pull-tester: Don't mute zmq ImportErrorMarcoFalke
Github-Pull: #8607 Rebased-From: fabfd5dae28cbe26e71d50dbfb6feab03673f27a
2016-09-21[qa] abandonconflict: Use assert_equalMarcoFalke
Github-Pull: #8531 Rebased-From: fa64306520156af1d1fe90e92f6cc22ffa097c02
2016-09-21[qa] Rework hd wallet dump testMarcoFalke
Github-Pull: #8442 Rebased-From: fa4439d3554435bdf0ef47861835f10d41bcdc1a