change(test): Require cached lightwalletd state for the send transaction tests (#4303)

* Revert "Temporarily stop requiring cached lightwalletd state for the send transaction tests"

This reverts commit f6b29b151e.

* fix(ci): add a lightwalletd cached state to the test

Co-authored-by: Gustavo Valverde <gustavo@iterativo.do>
This commit is contained in:
teor 2022-05-14 09:01:31 +10:00 committed by GitHub
parent 77529a8cbd
commit 94ba4b46a2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 7 deletions

View File

@ -255,7 +255,6 @@ jobs:
zebra_state_dir: 'zebrad-cache' zebra_state_dir: 'zebrad-cache'
# Test that Zebra can handle a lightwalletd send transaction RPC call, using a cached Zebra tip state # Test that Zebra can handle a lightwalletd send transaction RPC call, using a cached Zebra tip state
# TODO: use a cached lightwalletd tip state to speed up the test (#4303)
lightwalletd-transactions-test: lightwalletd-transactions-test:
needs: build needs: build
uses: ./.github/workflows/deploy-gcp-tests.yml uses: ./.github/workflows/deploy-gcp-tests.yml
@ -266,10 +265,12 @@ jobs:
test_description: Test sending transactions via lightwalletd test_description: Test sending transactions via lightwalletd
test_variables: '-e TEST_LWD_TRANSACTIONS=1 -e ZEBRA_TEST_LIGHTWALLETD=1 -e ZEBRA_FORCE_USE_COLOR=1 -e ZEBRA_CACHED_STATE_DIR=/var/cache/zebrad-cache -e LIGHTWALLETD_DATA_DIR=/var/cache/lwd-cache' test_variables: '-e TEST_LWD_TRANSACTIONS=1 -e ZEBRA_TEST_LIGHTWALLETD=1 -e ZEBRA_FORCE_USE_COLOR=1 -e ZEBRA_CACHED_STATE_DIR=/var/cache/zebrad-cache -e LIGHTWALLETD_DATA_DIR=/var/cache/lwd-cache'
needs_zebra_state: true needs_zebra_state: true
needs_lwd_state: true
saves_to_disk: false saves_to_disk: false
disk_suffix: tip disk_suffix: tip
root_state_path: '/var/cache' root_state_path: '/var/cache'
zebra_state_dir: 'zebrad-cache' zebra_state_dir: 'zebrad-cache'
lwd_state_dir: 'lwd-cache'
# Test full sync of lightwalletd with a Zebra tip state # Test full sync of lightwalletd with a Zebra tip state
lightwalletd-full-sync: lightwalletd-full-sync:

View File

@ -52,12 +52,7 @@ pub async fn run() -> Result<()> {
// We want a zebra state dir and a lightwalletd data dir in place, // We want a zebra state dir and a lightwalletd data dir in place,
// so `UpdateCachedState` can be used as our test type // so `UpdateCachedState` can be used as our test type
// let test_type = UpdateCachedState;
// But for now, we don't want to require the cached state, because it's not ready yet.
// TODO: use `UpdateCachedState`
let test_type = FullSyncFromGenesis {
allow_lightwalletd_cached_state: true,
};
let cached_state_path = test_type.zebrad_state_path("send_transaction_tests".to_string()); let cached_state_path = test_type.zebrad_state_path("send_transaction_tests".to_string());
if cached_state_path.is_none() { if cached_state_path.is_none() {