Commit Graph

1465 Commits

Author SHA1 Message Date
Kris Nuttycombe da5fbfe747
Merge pull request #6132 from sellout/rpc-test-improvements
RPC test improvements
2022-08-22 16:06:50 -06:00
Greg Pfeil 6766e39ad1 Add simplejson to requirements for rpc-tests 2022-08-22 13:38:16 -06:00
Greg Pfeil 113d7a4840 Add an `rpc-tests` make target
This ensures that zcashd is up-to-date with any changes before running the
tests.
2022-08-22 13:38:16 -06:00
Jack Grigg 8d82cee9c8 rust: Add `zcash-inspect` binary for inspecting Zcash data
Currently supports Zcash blocks, block headers, and transactions. Some
consensus rules are also checked, and a JSON context object can be
optionally passed to provide any necessary details for extra contextual
consensus checks.
2022-08-19 04:13:05 +00:00
Jack Grigg a2b971befb rust: Update some of the pinned dependencies
The primary purpose of this commit is an exercise in using `cargo vet`
for tracking audits of our Rust dependency updates. `cargo update` was
run, and then a simple-to-audit subset of the dependency updates were
audited and committed.
2022-08-17 10:39:38 +00:00
Jack Grigg 12c36670fe depends: Update Clang / libcxx to LLVM 14.0.6
In practice we are using 14.0.0 in most cases, as the LLVM Project have
not published Ubuntu binaries for any point release after 14.0.0 (which
we are using here).
2022-08-10 23:10:40 +00:00
Jack Grigg 93422e8fe2 depends: Update Rust to 1.62.1 2022-08-10 22:57:46 +00:00
Kris Nuttycombe 4a17098b72
Merge branch 'version-5.2.0' into narrow-too-many-args 2022-07-25 10:42:15 -06:00
Daira Hopwood a227652d7d Update cxx to 1.0.72.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2022-07-25 14:57:19 +01:00
Kris Nuttycombe e48d26eeb9 qa: Postpone recent native_rust, native_cxxbridge and rustcxx updates 2022-07-22 14:56:22 -06:00
Kris Nuttycombe 035a26b674 Replace setup_clean_chain with cache_behavior in rpc test init. 2022-07-18 09:00:34 -06:00
Kris Nuttycombe 6477c6165b Update getblocktemplate test to use persisted sprout chain 2022-07-18 09:00:34 -06:00
Kris Nuttycombe 91f62f4161 Update finalsaplingroot test to use persisted sprout chains. 2022-07-18 09:00:34 -06:00
Kris Nuttycombe 95bbfd09aa Update feature_zip239 test to use persisted sprout chains. 2022-07-15 08:23:57 -06:00
Kris Nuttycombe b2fc56c24a Update sprout_sapling_migration test to use persisted sprout chains. 2022-07-15 08:23:57 -06:00
Kris Nuttycombe afea5c386d Add RPC test initialization using the persisted Sprout chains. 2022-07-15 08:23:57 -06:00
Kris Nuttycombe 532017e74e Remove the temporary test that was used for setup of the cached Sprout fixtures. 2022-07-15 08:23:57 -06:00
Kris Nuttycombe 5d44ce318e Add persistent Sprout test data.
This is in preparation for removing the ability to generate
Sprout outputs from z_shieldcoinbase. Once that is complete,
we will no longer be able to use `z_shieldcoinbase` for test
setup for uses of Sprout funds; instead, the persisted blockchain
state created in this commit will be used for tests that require
the use of Sprout funds.

This brings the test framework into line with how Sprout funds
are now used on mainnet and testnet; existing Sprout funds may
be spent, and Sprout change may be created, but no funds may
be transfered into the Sprout pool, since the activation of
ZIP 211.
2022-07-15 08:23:57 -06:00
Kris Nuttycombe 40df3d402e
Merge pull request #6042 from nuttycom/feature/clock_capability
Add a clock for testing with an offset from the system clock.
2022-07-15 08:23:23 -06:00
Kris Nuttycombe e7922af588 Add a clock for testing with an offset from the system clock.
This change improves clock management for zcashd by ensuring
that all clock methods (obtaining seconds, milliseconds, and
microseconds since the epoch) agree under testing conditions
using `-mocktime`, and also adds a feature that allows tests
to specify an offset to the system clock; this is useful to
allow comprehensive testing of the "timejacking attack mitigation"
consensus rules.
2022-07-14 16:33:54 -06:00
zancas a4a0fbb3c0 match the actual two hyphen flag 2022-07-14 07:44:17 -06:00
str4d 050133358b
Merge pull request #6059 from superbaud/smoketest-minconf
Update smoke_test.py to compensate for changes in minimum confirmations required
2022-07-08 20:08:02 +01:00
Jack Grigg 884c149c64 qa: Postpone latest `cxx` update 2022-07-08 02:51:43 +00:00
sasha b72aaab820 Patch smoke_tests.py to require 4 confirmations for z_mergetoaddress 2022-07-07 01:22:40 -07:00
sasha 823c1b44c5 Improve smoke_test.py wait_for_balance message in the minconf!=1 case 2022-07-06 23:23:44 -07:00
sasha 61dd95ef0b Patch smoke_tests.py to properly handle changes in minconf behavior 2022-07-06 22:58:03 -07:00
Jack Grigg 343ddc1752 qa: Add native_cxxbridge and rustcxx to update checker 2022-07-05 21:45:59 +00:00
Jack Grigg 2e6a6572ba qa: Postpone dependency updates 2022-07-05 20:43:26 +00:00
Jack Grigg af59b2adb7 qa: Reformat for latest cargo-vet 2022-07-05 18:22:57 +00:00
Jack Grigg 90f13641b9 Use batch validation for Sapling proofs and signatures 2022-07-05 18:21:51 +00:00
Jack Grigg 5d9ae0ba63 bench: Add `ConnectBlock` benchmark using block 1723244
This block has 470 transactions, containing a total of 452 Sapling
spends and 1862 outputs, making for a nice benchmark of verification
performance.
2022-07-04 17:32:42 +00:00
therealyingtong da15ada52e Test getrawtransaction in wallet_orchard.py 2022-07-01 08:50:34 -04:00
Daira Hopwood e584b1b43f Upgrade to metrics 0.19.x and metrics-exporter-prometheus 0.10.x.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2022-07-01 09:12:34 +01:00
Jack Grigg 0430fdf20d Upgrade to `orchard 0.2.0` 2022-07-01 01:24:15 +00:00
Jack Grigg 107cb9636c cargo vet fmt 2022-07-01 01:24:15 +00:00
Jack Grigg 079ff9721f bench: Add `ConnectBlock` benchmark using block 1708048
This block has 88 Orchard transactions, containing a total of 552
actions, making for a nice benchmark of verification performance.
2022-07-01 01:24:15 +00:00
Jack Grigg e6d81e0fc1 qa: Generalise `extract_benchmark_data` in `performance-measurements.sh` 2022-07-01 01:24:15 +00:00
Jack Grigg eadfc028d6 qa: Fix `qa/zcash/create_benchmark_archive.py` script 2022-07-01 01:24:15 +00:00
mdr0id 9a867e2958 Update walletbackup.py 2022-06-28 17:10:53 -07:00
Jack Grigg ad369ca29f qa: Add audits for the crates directly maintained by the ECC core team 2022-06-09 17:00:15 +00:00
Jack Grigg 4b7445145d qa: Add `crypto-reviewed` and `license-reviewed` criteria for `cargo vet` 2022-06-09 15:53:57 +00:00
Jack Grigg 19c7742318 qa: `cargo vet init` 2022-06-09 14:50:23 +00:00
str4d e66f768e5d
Merge pull request #5976 from nuttycom/bug/block_wallet_init_on_reindex
Scan wallet from genesis when reindexing
2022-06-01 18:21:10 +01:00
Jack Grigg c1343d1807 qa: Fix sprout_sapling_migration RPC test to handle wallet RPC change
Co-authored-by: ying tong <yingtong@z.cash>
2022-06-01 13:51:26 +00:00
Kris Nuttycombe f3a9dcc0cf Mark the `dumpwallet` RPC method as disabled.
Fixes #5513
2022-05-26 14:31:26 -06:00
Kris Nuttycombe 9691d86047 Add a CLI flag to preferentially send V4 tx.
Since the wallet ecosystem may not be fully updated to handle
v5 transaction parsing at the point of NU5 activation, some
nodes may prefer to construct V4 transactions when not including
Orchard transaction components.

This change adds a CLI flag that allows node users to specify
that preference.
2022-05-26 07:26:38 -06:00
Kris Nuttycombe 15d1bb6ce9 scripted-diff: Add 2020-2022 copyright headers for files added/modified in 2020
-BEGIN VERIFY SCRIPT-
grep -l "Copyright" $(grep -L "The Zcash developers" $(git diff --name-only --diff-filter=ACM 6a08c225674df23f1c7f214bcb94732dba688d39..a960e896dd4c0b6d96db3d5ebbb1caa6c92a9f39 -- src/ test/ zcutil/ qa/)) | xargs -I {} sed -i"" -e "s#\(\(.*\)Copyright (c) .* The Bitcoin Core developers\)#\1\n\2Copyright (c) 2020-2022 The Zcash developers#" {}
-END VERIFY SCRIPT-
2022-05-11 17:32:39 -06:00
Kris Nuttycombe 940dd0d426 scripted-diff: Add 2019-2022 copyright headers for files added/modified in 2019
-BEGIN VERIFY SCRIPT-
grep -l "Copyright" $(grep -L "The Zcash developers" $(git diff --name-only --diff-filter=ACM 8df7a073ce13ec057b94b5a813bb5534cdfa6809..6a08c225674df23f1c7f214bcb94732dba688d39 -- src/ test/ zcutil/ qa/)) | xargs -I {} sed -i"" -e "s#\(\(.*\)Copyright (c) .* The Bitcoin Core developers\)#\1\n\2Copyright (c) 2019-2022 The Zcash developers#" {}
-END VERIFY SCRIPT-
2022-05-11 17:29:59 -06:00
Kris Nuttycombe 73fcef8035 scripted-diff: Add 2018-2022 copyright headers for files added/modified in 2018
-BEGIN VERIFY SCRIPT-
grep -l "Copyright" $(grep -L "The Zcash developers" $(git diff --name-only --diff-filter=ACM b2a114a8c99947b66d1fbdc70278f13e7a415d2a..8df7a073ce13ec057b94b5a813bb5534cdfa6809 -- src/ test/ zcutil/ qa/)) | xargs -I {} sed -i"" -e "s#\(\(.*\)Copyright (c) .* The Bitcoin Core developers\)#\1\n\2Copyright (c) 2018-2022 The Zcash developers#" {}
-END VERIFY SCRIPT-
2022-05-11 17:28:03 -06:00
Kris Nuttycombe d9aeefc54a scripted-diff: Add 2017-2022 copyright headers for files added/modified in 2017
-BEGIN VERIFY SCRIPT-
grep -l "Copyright" $(grep -L "The Zcash developers" $(git diff --name-only --diff-filter=ACM 94f427a211bb337200c29a1e19be0f5ad2f171b0..b2a114a8c99947b66d1fbdc70278f13e7a415d2a -- src/ test/ zcutil/ qa/)) | xargs -I {} sed -i"" -e "s#\(\(.*\)Copyright (c) .* The Bitcoin Core developers\)#\1\n\2Copyright (c) 2017-2022 The Zcash developers#" {}
-END VERIFY SCRIPT-
2022-05-11 17:25:51 -06:00