Simon
d72c19a662
Closes #2910 . Add z_listunspent RPC call.
2018-03-28 10:38:57 -07:00
Jack Grigg
31afbcc5c9
Ignore -mempooltxinputlimit once Overwinter activates
2018-03-28 14:25:42 +02:00
Homu
99b6f76355
Auto merge of #3111 - bitcartel:3110_high_fee_error_reporting, r=bitcartel
...
Closes #3110 . Ensure user can see error message about absurdly high fees.
2018-03-27 10:33:52 -07:00
Simon
8b15afd315
Closes #3110 . Ensure user can see error message about absurdly high fees.
2018-03-27 10:23:24 -07:00
Jack Grigg
b466c1c90c
cleanup: Ensure code is pyflakes-clean for CI
2018-03-27 02:47:57 +02:00
Homu
64de921747
Auto merge of #3091 - bitcartel:cache_invalidation_qa, r=str4d
...
Closes #1988 . Add qa test for cache invalidation bug found in v1.0.0 to v1.0.3.
2018-03-20 11:28:08 -07:00
Homu
70e2522306
Auto merge of #3090 - bitcartel:3084_log_expired_txid, r=bitcartel
...
Closes #3084 . Log txid when removing expired transactions from mempool.
2018-03-19 14:59:30 -07:00
Jack Grigg
b7caaf954b
test: Move wait_and_assert_operationid_status debug output before asserts
...
Otherwise we don't see them for failed tests :)
2018-03-19 14:00:18 +01:00
Simon
b740a99079
Remove local function wait_and_assert_operationid_status which is
...
now defined in the test framework for shared usage.
2018-03-16 17:16:22 -07:00
Simon
2f761371d2
Add qa test for cache invalidation bug found in v1.0.0 to v1.0.3.
2018-03-16 15:18:34 -07:00
Simon
a510b4752d
Enable mempool logging in tx expiry QA test.
2018-03-16 11:45:45 -07:00
Daira Hopwood
b4353db5d6
pyflakes cleanups to RPC tests after Overwinter PRs.
...
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2018-03-12 14:15:25 +00:00
Jonathan "Duke" Leto
4db8717431
Fix outdated comment about starting balance of nodes
2018-02-28 14:29:05 -08:00
Jonathan "Duke" Leto
48cecf2ad9
Regtest mining does have a founders reward, a single address t2FwcEhFdNXuFMv1tcYwaBJtYVtMj8b1uTg
2018-02-28 14:28:22 -08:00
Jonathan "Duke" Leto
62fee1296f
Update awkward wording about blocks as per @daira
2018-02-28 14:17:28 -08:00
Jonathan "Duke" Leto
d8399efc03
This library seems to not be used at all and all comments mentioning it are ghosts
2018-02-28 14:13:07 -08:00
Jonathan "Duke" Leto
427e5fae3f
Fix references to Bitcoin in RPC tests readme
2018-02-26 10:47:59 -08:00
Homu
a418756ef4
Auto merge of #2874 - arcalinea:tx_block_expiry, r=arcalinea
...
Transaction expiry height
Implements ZIP 203.
- Only applies after Overwinter blockheight.
Closes #754 .
2018-02-23 18:37:48 -08:00
Simon
b6e5cc7d27
Add python qa test overwinter_peer_management.
2018-02-23 14:22:43 -08:00
Jay Graber
5943f227da
Add mempool_tx_expiry.py test
2018-02-23 00:12:10 -08:00
Homu
c5904fb2a4
Auto merge of #2797 - str4d:2493-active-merging, r=bitcartel
...
Implement z_mergetoaddress for combining UTXOs and notes
Closes #2493 .
2018-02-22 20:59:51 -08:00
Jack Grigg
15ced9b153
wallet_mergetoaddress: Add additional syncs to prevent race conditions
2018-02-23 04:28:04 +00:00
Simon
e6cd2a8356
Closes #2964 . z_sendmany once again makes v1 tx for taddr to taddr.
...
In accordance with the Zcash protocol spec.
2018-02-22 15:43:42 +00:00
Jack Grigg
4c3d2b3bbe
Check upgrade status in wallet_overwintertx RPC test
2018-02-22 13:44:40 +00:00
Jack Grigg
553a5c1ab2
Gate z_mergetoaddress as an experimental feature
2018-02-22 13:23:25 +00:00
Jack Grigg
6e9c7629af
Implement z_mergetoaddress for combining UTXOs and notes
...
Closes #2493 .
2018-02-22 13:23:18 +00:00
Jack Grigg
ed9aa2b62a
Add branch IDs for current and next block to getblockchaininfo
...
Closes #2974 .
2018-02-21 21:18:03 +00:00
Homu
d4d2844829
Auto merge of #2463 - str4d:713-rollback-limit, r=str4d
...
Implement roll-back limit for reorganisation
Part of #2905 . Closes #713 .
2018-02-20 15:17:22 -08:00
Homu
49274558c6
Auto merge of #2940 - str4d:nu-activation-mempool-expiry, r=str4d
...
Mempool improvements, branch ID awareness
Whenever the local chain tip is updated, transactions in the mempool which commit to an
unmineable branch ID (for example, just before a network upgrade activates, where the
next block will have a different branch ID) will be removed.
Includes commits cherry-picked from the following upstream PRs:
- bitcoin/bitcoin#6654
- Only the mempool index change.
- bitcoin/bitcoin#6776
- bitcoin/bitcoin#7020
- bitcoin/bitcoin#6915
Part of #2074 .
2018-02-19 19:00:30 -08:00
Jack Grigg
34a64fe0a2
Remove mempool transactions which commit to an unmineable branch ID
2018-02-20 02:57:44 +00:00
Matt Corallo
b0f8c83f95
Add failing test checking timelocked-txn removal during reorg
2018-02-20 02:57:40 +00:00
Jack Grigg
57e6ecda5a
Implement roll-back limit for reorganisation
...
Closes #713 .
2018-02-19 16:32:42 +00:00
Simon
072099d788
Implementation of Overwinter transaction format ZIP 202.
2018-02-16 10:10:15 -08:00
Jack Grigg
9e8f1d09ca
zkey_import_export: Synchronize mempools before mining
...
Resolves a race condition that caused the RPC test to intermittently fail.
Closes #2892 .
2018-01-22 21:10:57 +00:00
Jack Grigg
44e5b42751
Check chainValueZat when checking value pool monitoring
2018-01-03 23:41:53 +01:00
Jack Grigg
5d9cf8ae23
Fix pyflakes warnings in zkey_import_export RPC test
2017-12-21 18:19:42 +00:00
Homu
1683c2d5bf
Auto merge of #2143 - str4d:1997-viewing-keys, r=str4d
...
Implement incoming viewing keys
Closes #1997 .
2017-12-20 14:11:05 -08:00
Jack Grigg
44e37656bf
Add watch-only support to Zcash RPC methods
...
Balance totals do not include spends linked to viewing key addresses, as
nullifiers cannot be calculated and therefore spends cannot be detected.
2017-12-20 00:46:37 +00:00
Homu
c1b0db70e5
Auto merge of #2779 - arcalinea:2515_test_zimportkey, r=str4d
...
Add RPC test that exercises z_importkey
Part of #2515 .
2017-12-18 08:32:28 -08:00
Homu
efda4bafef
Auto merge of #2796 - per-gron:less-verbose-tests, r=daira
...
Less verbose tests
Fixes #2453 and deduplicates some related code.
2017-12-17 00:22:38 -08:00
Per Grön
d4ab94a6d9
Print result of RPC call in test only when PYTHON_DEBUG is set
2017-12-16 19:24:25 +01:00
Per Grön
8993edfb77
Deduplicate test utility method wait_and_assert_operationid_status
...
Strictly speaking this is not a true deduplication; the test output will be
slightly different (due to inconsistent print statements) but I think this is
close enough.
2017-12-16 19:24:25 +01:00
Homu
7888624f74
Auto merge of #2795 - str4d:2351-sprout-circuit-value, r=str4d
...
Track net value entering and exiting the Sprout circuit
Delta values will be stored for new blocks; old blocks can be filled in by
re-indexing. The net value currently in the Sprout circuit is only calculated
when delta values for all previous blocks are present.
Part of #2351 .
2017-12-16 02:09:40 -08:00
Homu
f44a4cea42
Auto merge of #2790 - bitcartel:2746_payment_disclosure_prefix, r=str4d
...
Closes #2746 . Payment disclosure blobs now use 'zpd:' prefix.
2017-12-15 10:31:58 -08:00
Jay Graber
73b220cb0f
Add rpc test that exercises z_importkey
2017-12-15 10:15:50 -08:00
Jack Grigg
e319633435
Add Sprout value pool to getblock and getblockchaininfo
2017-12-14 22:06:15 +00:00
Simon
61345ae703
Closes #2746 . Payment disclosure blobs now use 'zpd:' prefix.
2017-12-07 10:11:43 -08:00
Homu
019c4bddc8
Auto merge of #2741 - bitcartel:stop_dumpwallet_overwriting, r=str4d
...
Prevent RPC calls dumpwallet and z_exportwallet from overwriting an existing file
Closes #2740
2017-12-04 09:41:52 -08:00
Simon
159aa37fc0
Closes #2759 . Fixes broken pipe error with QA test wallet.py.
2017-11-22 00:02:52 -08:00
Simon
ba1dbb3040
RPC dumpwallet and z_exportwallet updated to no longer allow
...
overwriting an existing file.
2017-11-16 22:29:37 -08:00
Simon
45232b1961
Add payment disclosure as experimental feature.
2017-11-14 13:29:05 -08:00
Simon
337bca8125
Fix an issue where qa test wallet_shieldcoinbase could hang.
...
The mempool was not synced so a block could be generated and not
clear out the mempool. This would then cause subsequent code
which expected the mempool of all nodes to be empty to hang.
2017-11-03 00:39:23 -07:00
Homu
3775ac5250
Auto merge of #2692 - bitcartel:2639_enable_z_shieldcoinbase, r=str4d
...
Closes #2639 . z_shieldcoinbase is now supported, no longer experimental.
This reverts commit 5023af7bd5
.
2017-11-02 00:18:40 -07:00
Simon
c5dabd2b66
Closes #2639 . Adds optional limit parameter with a default value of 50.
...
The new parameter is to satisfy the principle of least astonishment
by providing a sensible default for the maximum number of transparent
inputs to shield. If users do not configure -mempooltxinputlimit
it is possible for them to create transactions with hundreds of
inputs which suffer from mining delay, due to the current state of
the network where some miners have configured -mempooltxinputlimit
as a way to deal with the problem of quadratic hashing.
2017-11-01 10:40:24 -07:00
Simon
cf72e8e06e
Closes #2263 fixing broken pipe error.
2017-10-30 11:58:37 -07:00
Simon
c2d3bafeaa
Closes #2639 . z_shieldcoinbase is now supported, no longer experimental.
...
This reverts commit 5023af7bd5
.
2017-10-26 11:29:36 -07:00
Jack Grigg
5455ca0d0e
Fix BIP65 and BIP66 tests
...
Blocks were being created that didn't satisfy the regtest consensus rules.
2017-10-05 15:18:54 +01:00
Jack Grigg
c10c40779d
[Test] MiniNode: Implement Zcash coinbase
2017-10-05 15:18:53 +01:00
Jack Grigg
7596a4922d
[Test] MiniNode: Coerce OP_PUSHDATA bytearrays to bytes
...
If a bytearray is passed in as part of an iterable, the CScript constructor
fails because b''.join() cannot be used to join a bytearray to a bytes or str in
Python 2.
2017-10-05 15:18:31 +01:00
Jack Grigg
643235859a
[Test] MiniNode: Fix coinbase creation
...
CScriptNum is only used for heights > 16.
2017-10-05 15:18:27 +01:00
Jack Grigg
e68c3ec188
[Test] MiniNode: Use Zcash PoW
...
Equihash solver code extracted from https://github.com/str4d/zcash-pow
RPC tests now require pyblake2 to be installed
2017-10-05 15:15:10 +01:00
Jack Grigg
0de9a481ab
[Test] MiniNode: Update protocol version and network magics
2017-10-05 15:15:10 +01:00
Jack Grigg
31bc3d2581
[Test] MiniNode: Implement Zcash block parsing
2017-10-05 15:15:10 +01:00
Jack Grigg
c47dc872a7
[Test] MiniNode: Implement v2 CTransaction parsing
2017-10-05 15:15:10 +01:00
Jack Grigg
13ca1e8011
[Test] MiniNode: Implement JSDescription parsing
2017-10-05 15:15:06 +01:00
Jack Grigg
243b6a9d4b
Add connections in BIP65 and BIP66 tests to the test manager
...
Fixes a bug in the tests causing them to silently pass instead of correctly
reporting other errors. Introduced in 4a785b0a5b
during the test rewrites.
2017-10-03 17:41:37 +01:00
Homu
e806f9c603
Auto merge of #2638 - bitcartel:2637_experimental_feature_z_shieldcoinbase, r=str4d
...
Closes #2637 . Make z_shieldcoinbase an experimental feature.
Can be enabled with: `zcashd -experimentalfeatures -zshieldcoinbase`
2017-09-27 16:09:54 -07:00
Simon
5023af7bd5
Closes #2637 . Make z_shieldcoinbase an experimental feature where it
...
can be enabled with: zcashd -experimentalfeatures -zshieldcoinbase.
2017-09-27 10:43:54 -07:00
Jack Grigg
f897e075c2
Fix pyflakes warnings in RPC tests
2017-09-27 17:24:19 +01:00
Homu
f34c60de37
Auto merge of #2615 - bitcartel:2448_shield_coinbase, r=bitcartel
...
Add RPC command shield_coinbase #2448 .
Shield transparent coinbase funds by sending to a shielded z address. Closes #2448 .
2017-09-22 12:04:31 -07:00
Simon
06c19063bb
Implement RPC shield_coinbase #2448 .
2017-09-21 15:04:12 -07:00
Homu
8f16b27304
Auto merge of #2616 - nathan-at-least:importprivkey-shows-address.4, r=str4d
...
Importprivkey shows address
Scratching an itch: make `importprivkey` output the corresponding address.
Without this PR, `importprivkey` shows no output. Because we're moving towards an "address-based" RPC interface, rather than "account-based", there's a gap when using `importprivkey` because there's no way to assign it to a specific account, but also no easy way to determine the address. This change fixes that wart.
2017-09-21 14:29:03 -07:00
Jack Grigg
109fed51ff
Additional test cases for importprivkey RPC test
2017-09-21 22:21:44 +01:00
Simon
5a0721f0fe
Set up a clean chain.
...
Delete redundant method wait_until_miner_sees() via use of sync_all().
2017-09-19 20:42:53 -07:00
Simon
b17e1b4080
Closes #2583 . Exclude watch-only utxos from z_sendmany coin selection.
2017-09-19 19:42:48 -07:00
Nathan Wilcox
3e92c028ce
Add a new requirement that `importprivkey` API is idempotent.
2017-09-18 15:30:42 +09:00
Nathan Wilcox
63cdea4233
Add a new rpc-test-specified requirement: `importprivkey` outputs the associated address. (Test fails.)
2017-09-18 15:30:42 +09:00
Nathan Wilcox
d29b6b042f
key_import_export rpc-test: verify that UTXO view co-evolves for nodes sharing a key.
2017-09-18 15:30:42 +09:00
Homu
1738e6957f
Auto merge of #2458 - daira:2450.pyflakes-cleanup, r=str4d
...
pyflakes cleanup
Make the RPC tests pyflakes-clean. fixes #2450
Includes a fix that upstream had in https://github.com/bitcoin/bitcoin/pull/7802
2017-07-14 18:03:03 -07:00
Simon
d77a0ac4a0
Closes #2446 by adding generated field to listunspent.
...
If generated is true, the unspent transaction output is from a
coinbase transaction and can only be sent to a shielded address.
2017-07-11 10:44:36 -07:00
Daira Hopwood
ff0f305497
Cosmetics (trailing whitespace, comment conventions, etc.)
...
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2017-06-22 18:09:05 +01:00
Daira Hopwood
811b36ba80
For unused variables reported by pyflakes, either remove the variable,
...
suppress the warning, or fix a bug (if the wrong variable was used).
refs #2450
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2017-06-22 18:09:05 +01:00
Daira Hopwood
aff0bf7fa1
Clean up imports to be pyflakes-checkable. fixes #2450
...
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2017-06-22 18:09:04 +01:00
Homu
59de56eeca
Auto merge of #2342 - bitcartel:1081__mempoolpatch, r=str4d
...
Add ability for node to reject tx from mempool by number of tx inputs
Implement short-term solution described in #2343 so that users can respond promptly to critical short-term problems caused by quadratic validation scaling, such as the getblocktemplate latency, block propagation latency, and mempool size inflation issues described in #2333 .
2017-06-21 14:42:13 -07:00
Jack Grigg
6ea58d1531
Use sendfrom for both t-addr calls
2017-06-22 09:34:10 +12:00
Simon
99f6d5da6c
Fix #b1eb4f2 so test checks sendfrom as originally intended.
...
Also reduce number of z_sendmany calls made so test runs quicker.
2017-06-20 22:49:47 +00:00
Daira Hopwood
193b3e8b28
Delete test that is redundant and inapplicable to Zcash.
...
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2017-06-20 10:03:17 +01:00
Jack Grigg
b1eb4f251a
Fix comment
2017-06-20 19:54:11 +12:00
Jack Grigg
4ef014151d
Additional testing of -mempooltxinputlimit
2017-06-20 15:58:46 +12:00
Daira Hopwood
4a785b0a5b
Repair tests for strict DER signatures.
...
While we're at it, repair a similar test for CLTV, and make the repaired RPC tests run by default.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2017-06-19 16:32:15 +01:00
Homu
73676ce6d6
Auto merge of #2200 - str4d:1884-tx-priority-test, r=nathan-at-least
...
Fix prioritisetransaction RPC test
Part of #1884 .
2017-05-16 11:54:49 -07:00
zkbot
ab3c2fe7b0
Auto merge of #2265 - daira:2263.fix-rpc-error-reporting, r=daira
...
Fix an error reporting bug due to BrokenPipeError and ConnectionResetError not existing in Python 2
refs #2263
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2017-04-16 16:56:16 +00:00
zkbot
f7f764e0b2
Auto merge of #2189 - bitcartel:1.0.7_with_apache_qpid, r=bitcartel
...
Add AMQP 1.0 support via Apache Qpid Proton C++ API 0.17.0
Closes #2188
2017-04-16 15:09:19 +00:00
Jay Graber
0a56135336
Poll on getblocktemplate result rather than use bare sleep to avoid race condition.
2017-04-14 17:31:35 -07:00
Daira Hopwood
80cbdbc749
Fix an error reporting bug due to BrokenPipeError and ConnectionResetError not existing in Python 2.
...
refs #2263
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2017-04-14 21:40:30 +01:00
Simon
99eb947a98
Add AMQP 1.0 support via Apache Qpid Proton C++ API 0.17.0
2017-03-25 08:51:40 -07:00
Wladimir J. van der Laan
f3e1770cfb
tests: Disable Tor interaction
...
This is unnecessary during the current tests (any test for Tor
interaction can explicitly enable it) and interferes with the proxy
test.
2017-03-25 20:25:38 +13:00
zkbot
f9f48667be
Auto merge of #2176 - str4d:1593-libevent, r=bitcartel
...
libevent-based http server
Cherry-picked from the following upstream PRs:
- bitcoin/bitcoin#5677
- bitcoin/bitcoin#6695
- bitcoin/bitcoin#6899
- bitcoin/bitcoin#7016
- bitcoin/bitcoin#7964
- bitcoin/bitcoin#8722
- bitcoin/bitcoin#8730
- bitcoin/bitcoin#9073
- bitcoin/bitcoin#9265
- bitcoin/bitcoin#9387
- bitcoin/bitcoin#9471
- bitcoin/bitcoin#9647
- bitcoin/bitcoin#9903
- bitcoin/bitcoin#6640
- bitcoin/bitcoin#8139
- bitcoin/bitcoin#8839
Closes #1593 and #1856 .
2017-03-25 04:52:16 +00:00
Wladimir J. van der Laan
e93a3e1945
test: Avoid ConnectionResetErrors during RPC tests
...
This is necessary on FreeBSD and MacOSX, at least.
See https://github.com/bitcoin/bitcoin/pull/8834#issuecomment-250450213
2017-03-24 18:43:40 +13:00
Pieter Wuille
2edad86b2d
Fix interrupted HTTP RPC connection workaround for Python 3.5+
2017-03-24 18:43:21 +13:00
zkbot
6344719817
Auto merge of #2052 - str4d:2032-z_importkey-partial-rescan, r=bitcartel
...
Usability improvements for z_importkey
- Add height parameter to z_importkey to reduce rescan range
- Change semantics of rescan parameter, so users can explicitly force a rescan
for existing keys.
Closes #2032
2017-03-24 03:47:11 +00:00
Jack Grigg
53c96bfa6c
Test boolean fallback in z_importkey
2017-03-24 09:23:11 +13:00
Wladimir J. van der Laan
7b41e725d0
Make RPC tests cope with server-side timeout between requests
...
Python's httplib does not graciously handle disconnections from the http server, resulting in BadStatusLine errors.
See https://bugs.python.org/issue3566 "httplib persistent connections violate MUST in RFC2616 sec 8.1.4."
This was fixed in Python 3.5.
Work around it for now.
2017-03-24 09:03:59 +13:00
Wladimir J. van der Laan
cc14ac45f4
tests: GET requests cannot have request body, use POST in rest.py
...
Sending a request body with GET request is not valid in HTTP spec, and
not compatible with evhttpd.
2017-03-24 09:03:59 +13:00
Wladimir J. van der Laan
14dcc6ab96
qa: Remove -rpckeepalive tests from httpbasics
...
This option was a temporary workaround, and is no longer necessary
with the new web server.
2017-03-24 09:03:59 +13:00
Jack Grigg
bec25c91cb
Revert "Closes #1680 , temporary fix for rpc deadlock inherited from upstream."
...
This reverts commit f4404d7b5b
.
2017-03-24 09:03:59 +13:00
Jack Grigg
dec148f498
Fix prioritisetransaction RPC test
...
Part of #1884 .
2017-03-23 18:57:46 +13:00
Jack Grigg
b7e5b7d5ee
Simplify z_importkey by making rescan a string
...
Transparently handles older boolean values as well.
2017-03-23 15:57:11 +13:00
Jack Grigg
a31ba7a0cb
Usability improvements for z_importkey
...
- Add height parameter to z_importkey to reduce rescan range
- Change semantics of rescan parameter, so users can explicitly force a rescan
for existing keys.
Closes #2032
2017-03-16 19:34:41 +13:00
Jack Grigg
542a7a40f1
Add tests for getmempoolinfo
2017-03-16 14:30:16 +13:00
Pavel Janík
30c163d99d
Implement REST mempool API, add test and documentation.
2017-03-14 13:52:06 +13:00
zkbot
a7cf698873
Auto merge of #2100 - str4d:2074-rpc, r=arcalinea
...
Bitcoin 0.12 RPC PRs 1
Cherry-picked from the following upstream PRs:
- bitcoin/bitcoin#6266
- bitcoin/bitcoin#6257
- bitcoin/bitcoin#6271
- bitcoin/bitcoin#6158
- bitcoin/bitcoin#6307
- bitcoin/bitcoin#6290
- bitcoin/bitcoin#6262
- bitcoin/bitcoin#6088
- bitcoin/bitcoin#6339
- bitcoin/bitcoin#6299 (partial, remainder in #2099 )
- bitcoin/bitcoin#6350
- bitcoin/bitcoin#6247
- bitcoin/bitcoin#6362
- bitcoin/bitcoin#5486
- bitcoin/bitcoin#6417
- bitcoin/bitcoin#6398 (partial, remainder was included in #1950 )
- bitcoin/bitcoin#6444
- bitcoin/bitcoin#6456 (partial, remainder was included in #2082 )
- bitcoin/bitcoin#6380
- bitcoin/bitcoin#6970
Part of #2074 .
2017-03-04 02:57:46 +00:00
zkbot
dadb1ab74c
Auto merge of #2101 - str4d:2074-tests, r=arcalinea
...
Bitcoin 0.12 test PRs 1
Cherry-picked from the following upstream PRs:
- bitcoin/bitcoin#6337
- bitcoin/bitcoin#6390
- bitcoin/bitcoin#5515
- bitcoin/bitcoin#6287 (partial, remainder included in bitcoin/bitcoin#6703)
- bitcoin/bitcoin#6465
Part of #2074 .
2017-03-03 21:25:03 +00:00
Casey Rodarmor
df8f8095b6
Don't share objects between TestInstances
2017-03-03 11:47:12 -08:00
Wladimir J. van der Laan
7cc6648341
tests: Extend RPC proxy tests
...
Also test -noonion
2017-03-03 10:57:13 -08:00
Jack Grigg
25b8f796ff
Re-encode t-addrs in disablewallet.py with Zcash prefixes
2017-03-02 13:26:34 -08:00
Jack Grigg
5329495fe4
Adjust fundrawtransaction RPC test for Zcash
...
- Enable wallet encryption
- Correct block reward
2017-03-02 13:26:34 -08:00
Wladimir J. van der Laan
56215c77d8
Fix crash in validateaddress with -disablewallet
...
Fix a null pointer dereference in validateaddress with -disablewallet. Also add a regression testcase.
2017-03-02 13:26:34 -08:00
Jonas Schnelli
c2616abb3c
[QA] add testcases for parsing strings as values
2017-03-02 13:26:34 -08:00
Wladimir J. van der Laan
d101d7b8e6
univalue: Avoid unnecessary roundtrip through double for numbers
...
JSON makes no distinction between numbers and reals, and our code
doesn't need to do so either.
This removes VREAL, as well as its specific post-processing in
`UniValue::write`. Non-monetary amounts do not need to be forcibly
formatted with 8 decimals, so the extra roundtrip was unnecessary
(and potentially loses precision).
Zcash: cherry-picked from commit 7650449a6777710cf818d41862626164da0cd412
Left over from 2aee461930
2017-03-02 13:26:34 -08:00
zathras-crypto
a11c4bbd26
Exempt unspendable transaction outputs from dust checks
...
Since unspendable outputs can't be spent, there is no threshold at which it would be uneconomic to spend them.
This primarily targets transaction outputs with `OP_RETURN`.
---
Initially based on:
commit 9cf0ae26350033d43d5dd3c95054c0d1b1641eda
Author: zathras-crypto <zathrasc@gmail.com>
Date: Wed Mar 25 02:04:02 2015 -0700
Changes:
- cherry-picked on top of bitcoin:master
- added RPC test for fundrawtransaction
2017-03-02 13:26:34 -08:00
Jonas Schnelli
5bfd954fc6
[QA] remove rawtransactions.py from the extended test list
...
rawtransactions.py is already in the standard test list
2017-03-02 13:23:03 -08:00
Jonas Schnelli
897a370c39
[QA] fix possible reorg issue in rawtransaction.py/fundrawtransaction.py RPC test
...
- added missing mempool sync between block generations
2017-03-02 13:23:03 -08:00
Jonas Schnelli
81eb80d841
[REST] add JSON support for /rest/headers/
2017-03-02 13:23:03 -08:00
mruddy
81ae51c883
add tests for the decodescript rpc. add mention of the rpc regression tests to the testing seciton of the main readme.
2017-03-02 13:23:03 -08:00
Jonas Schnelli
788d8e6a6f
fundrawtransaction tests
2017-03-02 13:23:03 -08:00
Jonas Schnelli
2ab237a088
add RPC tests for setban & disconnectnode
2017-03-02 13:23:03 -08:00
Jonas Schnelli
e521939942
[RPC] extend setban to allow subnets
2017-03-02 13:23:03 -08:00
Jonas Schnelli
962ec4b5e4
[QA] add setban/listbanned/clearbanned tests
2017-03-02 13:23:03 -08:00
Stephen
6699b42518
Add paytxfee to getwalletinfo, warnings to getnetworkinfo
2017-03-02 13:23:03 -08:00
zkbot
6ee75b3b7b
Auto merge of #2014 - arcalinea:test-prioritisetransaction, r=arcalinea
...
Test prioritisetransaction
After talking with @str4d about #1884 , I wrote a test for prioritisetransaction. It uses small blocks (11kb), and checks whether a transaction makes it into the next block after being prioritized by that node.
Should this be improved with a larger number of txs in the mempool, or by testing over multiple runs?
As for getblocktemplate(), it seems to return the prioritized transaction within the block size set by the node (about 50 txs fit in an 11kb block), but the block "sizelimit" it displays is set at 2 MB in `rpcmining.cpp` line 690:
```
result.push_back(Pair("sizelimit", (int64_t)MAX_BLOCK_SIZE));
```
This was quite confusing, I didn't think the `-blockmaxsize` parameter I was setting was working for awhile.
2017-03-02 06:47:04 +00:00
Simon
85c9ecb846
Part of #1969 . Update tests to avoid error 'absurdly high fee' from change in min fee calc.
2017-02-28 11:44:51 -08:00
Simon
ebe750a882
Part of #1969 . Changing min fee calculation also changes the dust threshold.
2017-02-28 11:44:07 -08:00
Jay Graber
8d2dac6e3f
Inc num of txs in test mempool
2017-02-27 14:11:09 -08:00
Jay Graber
cc64e2ccc8
Add rpc test for prioritisetransaction
2017-02-12 11:01:45 -08:00
Simon
238fec642d
Update test to check for updated error messages in AmountFromValue().
2017-02-09 23:32:15 -08:00
zkbot
7d4ced95ed
Auto merge of #2056 - str4d:2035-experimental-mode, r=bitcartel
...
Add a flag for enabling experimental features
Closes #2035 .
2017-02-09 23:39:02 +00:00
zkbot
d32511c72c
Auto merge of #2054 - str4d:2030-decoderawtransaction-joinsplit-fields, r=bitcartel
...
Show all JoinSplit components in getrawtransaction and decoderawtransaction
Closes #2030 .
2017-02-09 22:56:01 +00:00
Simon
91270dcfbc
Update test to check for more joinsplit related fields in getrawtransaction
2017-02-09 14:48:58 -08:00
Jack Grigg
b8eb37757b
Require -experimentalmode for wallet encryption
2017-02-09 22:10:58 +00:00
zkbot
253c610783
Auto merge of #2050 - str4d:2020-zmq, r=bitcartel
...
Add ZeroMQ notifications
Cherry-picked from the following upstream PRs:
- bitcoin/bitcoin#6103
- bitcoin/bitcoin#6684
- bitcoin/bitcoin#6686
- bitcoin/bitcoin#6736
- bitcoin/bitcoin#6739
- bitcoin/bitcoin#6743
- bitcoin/bitcoin#6768
- bitcoin/bitcoin#6779
- bitcoin/bitcoin#6810
- bitcoin/bitcoin#6927
- bitcoin/bitcoin#6980 (only upgrading zeromq)
- bitcoin/bitcoin#6680
- bitcoin/bitcoin#7058
- bitcoin/bitcoin#7621
- bitcoin/bitcoin#7335 (only parts affecting `zmq_test.py`)
- bitcoin/bitcoin#7853 (only parts affecting `zmq_test.py`)
- bitcoin/bitcoin#7762
- bitcoin/bitcoin#7993 (only upgrading zeromq)
- bitcoin/bitcoin#8238
- bitcoin/bitcoin#8701
- bitcoin/bitcoin#6685
Closes #2020 .
2017-02-09 20:08:15 +00:00
zkbot
b2e2dccc64
Auto merge of #2068 - bitcartel:2045_sendmany_fee_zero, r=bitcartel
...
Closes #2045 by allowing z_sendmany with 0 fee
2017-02-09 18:56:44 +00:00
Jack Grigg
8db0dd93e4
Add test to check for presence of vpub_old & vpub_new in getrawtransaction
2017-02-09 16:38:01 +00:00
Simon
75bb764bb8
Add test for z_sendmany with fee of 0
2017-02-08 15:26:33 -08:00
Jonas Schnelli
3ba2e19e2b
[ZMQ] append a message sequence number to every ZMQ notification
2017-02-08 22:11:53 +00:00
Jack Grigg
c7cb3c13ea
[qa] py2: Unfiddle strings into bytes explicitly in ZMQ RPC test
...
Extracted from bitcoin/bitcoin#7853
commit faa41ee204124da19dcf1e5b8a3aef1e216bf5e6
2017-02-08 22:11:53 +00:00
Jack Grigg
a9445db62f
Fix python syntax in ZMQ RPC test
...
Extracted from bitcoin/bitcoin#7335
commit 7777994846cdb9b9cf69e391a33eeed30393bbcf
2017-02-08 22:11:53 +00:00
Cory Fields
5088de4bb8
travis: install a recent libzmq and pyzmq for tests
2017-02-08 22:10:42 +00:00
Jonas Schnelli
5c7f84cf26
[travis] add zmq python module
2017-02-08 22:10:42 +00:00
Jonas Schnelli
da0e7aa1d7
QA: Add ZeroMQ RPC test
2017-02-08 22:10:42 +00:00
Simon
aa0ab69a15
Closes #2024 by documenting and testing method field in z_getoperationstatus
2017-02-06 14:53:56 -08:00
Simon
a45d2ec79c
Update test to verify order of zrpcunsafe log messages
2017-02-01 14:41:35 -08:00
Simon
a1477f6fac
Add test to verify z_sendmany logging
2017-02-01 11:02:03 -08:00
zkbot
0edb3c0f16
Auto merge of #1978 - str4d:1941-scan-whole-chain-on-zkey-import, r=ebfull
...
Scan the whole chain whenever a z-key is imported
Closes #1941 .
2017-01-20 00:02:12 +00:00
Sean Bowe
620c0e2845
Add test for z_importkey rescanning from beginning of chain.
2017-01-19 16:59:29 -07:00
zkbot
78674ca79e
Auto merge of #2007 - bitcartel:1097_copyright_notice_and_date, r=bitcartel
...
Closes #1097 so that zcash-cli displays license info like zcashd.
LicenseInfo is refactored from init.cpp to util.cpp so that the
bitcoin-cli makefile target does not need to be modified.
2017-01-19 00:56:47 +00:00
Simon
774489569a
Increase timeout for z_sendmany transaction in wallet.py qa test
2017-01-18 16:54:39 -08:00
zkbot
63e0e895a5
Auto merge of #2006 - bitcartel:1497_destination_path_validation_when_exporting, r=bitcartel
...
Fixes #1497 ZCA-009 by restricting export to a user defined folder and sanitizing filenames
2017-01-18 18:19:50 +00:00
Simon
bab89e35c7
Update walletbackup.py qa test to use -exportdir option
2017-01-18 10:05:49 -08:00
Simon
8aa7937d44
Fixes #1960 : z_getoperationstatus/result now includes operation details.
2017-01-16 16:45:27 -08:00
zkbot
02bb4df58d
Auto merge of #1918 - bitcartel:timeout_cpu_throttling, r=str4d
...
Increase timeout as laptops on battery power have cpu throttling.
Merge this last as other PRs also update the test file `wallet_protectcoinbase.py`.
2016-12-09 09:03:37 +00:00
zkbot
0617e428e2
Auto merge of #1895 - bitcartel:1857_tx_priority, r=str4d
...
Closes #1857 . Fixes bug where a transaction sending from a zaddr would have a priority of zero.
Transactions sent from a zaddr should now be mined sooner as they no longer have a priority of zero
2016-12-09 08:10:21 +00:00
zkbot
e68e26c208
Auto merge of #1911 - bitcartel:1823_witness_does_not_have_same_anchor_as_change_input, r=str4d
...
With chained joinsplits, witness anchors for input notes no longer cross block boundaries
Closes #1823
2016-12-08 01:23:40 +00:00
Simon
f3c4919027
Increase timeout as laptops on battery power have cpu throttling.
2016-12-05 10:46:12 -08:00
Simon
2d931e905b
Fixes #1823 . Witness anchors for input notes no longer cross block boundaries.
2016-12-03 00:22:42 -08:00
Simon
af53da0225
Closes #1903 . Add fee parameter to z_sendmany.
2016-11-30 14:23:35 -08:00
Simon
520ced1405
Closes #1857 . Fixes bug where tx spending only notes had priority of 0.
2016-11-28 22:54:49 -08:00
Simon
0afd3687c8
Closes #1854 . z_sendmany selects more utxos to avoid dust change output.
2016-11-15 17:12:37 -08:00
Simon
9ddb6ad028
Mempool will accept tx with joinsplits and the default z_sendmany fee.
...
Issue #1851 shows that a zaddr->taddr can be rejected from mempools
due to not meeting fee requirements given the size of the transaction.
Fee calculation for joinsplit txs has not yet been agreed upon, so
during this interim period, this patch ensures joinsplit txs using
the default fee are not rejected due to an insufficient fee.
2016-11-15 11:32:59 -08:00
zkbot
4e72614fb0
Auto merge of #1847 - bitcartel:1680_rpckeepalive_deadlock, r=ebfull
...
Closes #1680 , temporary fix for rpc deadlock inherited from upstream.
2016-11-15 10:25:24 +00:00
Simon
f4404d7b5b
Closes #1680 , temporary fix for rpc deadlock inherited from upstream.
2016-11-15 00:31:24 -08:00
Simon
9384e74c50
Closes #1833 . Format currency amounts in z_sendmany error message.
...
Improve coverage of possible error states from z_sendmany.
Refactor qa test for z_sendmany operations.
2016-11-10 16:57:36 -08:00
Simon
3920292b43
Add transaction size and zaddr output limit checks to z_sendmany.
2016-11-07 09:29:56 -08:00
Simon
7c463780cf
Fixes #1779 so that sending to multiple zaddrs no longer fails.
...
Commit 2eeb6b randomized the order of input and output notes,
but this is now known to prevent the chaining of multiple joinsplits
in a single transaction. The root cause has yet to be determined.
This patch is a temporary fix and disables the shuffling of input
and output notes. It also adds a chained joinsplit test to the
python qa test suite.
2016-11-04 23:23:48 -07:00
Sean Bowe
52676958d1
Test that a pure joinsplit will mine if other transactions are in the mempool.
2016-11-02 14:25:07 -06:00
Simon
db026807b8
Add z_sendmany rule that when sending coinbase utxos to a zaddr
...
they must be consumed entirely, without any change, since there
is currently no way to specify a change address in z_sendmany.
2016-10-24 21:34:16 -07:00
zkbot
a294b26db7
Auto merge of #1375 - str4d:1331-node-metrics, r=daira
...
Add node metrics screen
Continuation of #1336
Closes #1331
2016-10-22 20:21:11 -04:00
Daira Hopwood
02a4ace02c
Disable metrics screen in RPC tests
...
Author: Jack Grigg <jack@z.cash>
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2016-10-23 01:05:57 +01:00
zkbot
026c3f784f
Auto merge of #1602 - str4d:1424-minimal-getblocktemplate, r=daira
...
Minimal modifications to getblocktemplate
A simpler alternative to #1435 that ensures Zcash GBT will remain compatible with BIP 22.
Closes #1424
2016-10-22 16:40:59 -04:00
Jack Grigg
bc54cf06cc
Fix RPC test
2016-10-22 15:36:38 -05:00
Jack Grigg
07064ea2d1
GBT: Add RPC tests
2016-10-21 23:38:37 -05:00
Jack Grigg
1628efedaf
GBT: Correct block header in proposals RPC test
2016-10-21 23:36:35 -05:00
zkbot
48888b67c9
Auto merge of #1599 - daira:1597.fix-other-potential-race-conditions, r=daira
...
Fix other potential race conditions similar to ref #1597 in RPC tests.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2016-10-22 00:15:32 -04:00
zkbot
71043784dd
Auto merge of #1586 - bitcartel:z_sendmany_amount_too_strict, r=daira
...
Fix issue where z_sendmany amount parameter is too strict
Upstream treats an amount parameter of `1` the same as `1.0`. Third-party would like this fixed.
2016-10-21 22:10:41 -04:00
Daira Hopwood
deba66ca55
Fix other potential race conditions similar to ref #1597 in RPC tests.
...
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2016-10-22 00:37:14 +01:00
Daira Hopwood
f0f838f081
Fix race condition in rpc-tests/wallet_protectcoinbase.py. closes #1597
...
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2016-10-21 17:20:36 +01:00
Simon
5eed758493
Update test to use integer amount as well as decimal amount when calling z_sendmany
2016-10-20 17:10:25 -07:00
Jack Grigg
2b499f4386
Fix RPC tests that require wallet encryption
2016-10-20 14:35:41 -05:00
zkbot
ec8dc3a88a
Auto merge of #1431 - bitcartel:master_1373_taddr_coinbase_error, r=bitcartel
...
Return a more informative error message when trying to spend coinbase; select non-coinbase inputs when sending to a transparent output if needed
For #1373 and #1519
Code change:
- Extra parameter added to AvailableCoins to include or exclude Coinbase coins. Default value of parameter is 'true' as current behaviour is to include Coinbase coins.
- SelectCoins, used for sending taddr->taddr, will now exclude Coinbase coins.
Unit test:
Tried to write a test to focus on the extra parameter added to AvailableCoins but could not.
Empirical testing on Testnet:
Current behaviour is that upstream RPC commands sendfrom and sendtoaddress try to spend coinbase coins returned by AvailableCoins. So the user will see:
```
./zcash-cli sendtoaddress mrEGRmGJhmwAa4MQjzGd86ry63vrvovu9b 1000.0
error: {"code":-6,"message":"Insufficient funds"}
./zcash-cli sendtoaddress mrEGRmGJhmwAa4MQjzGd86ry63vrvovu9b 0.00003000
error: {"code":-4,"message":"Error: The transaction was rejected! This might happen if some of the coins in your wallet were already spent, such as if you used a copy of wallet.dat and coins were spent in the copy but not marked as spent here."}
./zcash-cli sendfrom "" mrEGRmGJhmwAa4MQjzGd86ry63vrvovu9b 0.00003000
error: {"code":-4,"message":"Error: The transaction was rejected! This might happen if some of the coins in your wallet were already spent, such as if you used a copy of wallet.dat and coins were spent in the copy but not marked as spent here."}
```
After fix is applied:
```
./zcash-cli sendtoaddress mrEGRmGJhmwAa4MQjzGd86ry63vrvovu9b 1000.0
error: {"code":-6,"message":"Insufficient funds"}
./zcash-cli sendtoaddress mrEGRmGJhmwAa4MQjzGd86ry63vrvovu9b 0.00003000
error: {"code":-4,"message":"Coinbase funds can only be sent to a zaddr"}
```
When non-coinbase UTXOs exist, they will now be selected and used:
```
./zcash-cli z_sendmany tnPJZHeVxegCg91utaquBRPEDBGjozfz9iLDHt7zvphFbZdspNgkTVLCGjDcadQBKNyUwKs8pNjDXuEZKrE1aNLpFwHgz4t '[{"address":"mx5fTRhLZwbYE7ZqhAPueZgQGSnwTbdvKU", "amount":0.01}]'
./zcash-cli sendtoaddress mrEGRmGJhmwAa4MQjzGd86ry63vrvovu9b 1000.0
error: {"code":-6,"message":"Insufficient funds"}
./zcash-cli sendtoaddress mrEGRmGJhmwAa4MQjzGd86ry63vrvovu9b 0.00003000
9818e543ac2f689d4ce8b52087607d73fecd771d45d316a1d9db092f0485aff2
./zcash-cli sendfrom "" mrEGRmGJhmwAa4MQjzGd86ry63vrvovu9b 0.00003000
899f2894823f51f15fc73b5e0871ac943edbe0ff88e1635f86906087b72caf30
```
2016-10-16 22:08:07 -04:00
Simon
2b1cda3b6a
Return improved error message when trying to spend Coinbase coins ( #1373 ).
...
Extra parameter added to AvailableCoins to include or exclude Coinbase coins.
SelectCoins, used for sending taddr->taddr, will exclude Coinbase coins.
Added qa rpc test and a runtime parameter -regtestprotectcoinbase to enforce
the coinbase->zaddr consensus rule in regtest mode.
2016-10-16 19:05:56 -07:00
Jack Grigg
ddea44a27e
Update comments
2016-10-14 17:16:09 -05:00
Jack Grigg
1a62587e9a
Delay caching of nullifiers when wallet is locked
...
Closes #1502
2016-10-14 17:16:09 -05:00
Jack Grigg
8f445ee774
Break the RPC test by encrypting the mirroring wallet
2016-10-14 17:14:13 -05:00
Jack Grigg
52fdce985f
Add RPC test showing correct handling of JS txns from blockchain
...
For unencrypted wallets, the wallet correctly tracks JoinSplits made for their
zkey in a different wallet.
2016-10-14 17:14:13 -05:00
zkbot
7dc49cbc6a
Auto merge of #1490 - str4d:1454-deprecate-accounts, r=bitcartel
...
Throw an RPC error for all accounts except the default
Closes #1454
2016-10-10 23:55:02 -04:00
Daira Hopwood
3040239e2a
Cosmetics in RPC tests.
...
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2016-10-10 20:27:16 +01:00
Daira Hopwood
218ded68f3
Fix RPC tests to not rely on accounts.
...
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2016-10-10 20:26:52 +01:00
Simon
f7cfb52d3c
Add vjoinsplit to JSON output of RPC call gettransaction
2016-10-06 19:53:46 -07:00
Daira Hopwood
db5dd18c16
Repair rpc-tests/signrawtransactions.py.
...
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2016-10-04 23:04:19 +01:00
Jack Grigg
f92f004714
Fix zkey test
2016-10-04 11:05:57 -07:00