feat(ci): add `fully_synced_rpc_test` test to CI (#4223)
* feat(ci): add lightwalletd RPC call test Co-authored-by: teor <teor@riseup.net>
This commit is contained in:
parent
d720ab011a
commit
a23420be88
|
@ -33,7 +33,6 @@ on:
|
||||||
needs_zebra_state:
|
needs_zebra_state:
|
||||||
required: true
|
required: true
|
||||||
type: boolean
|
type: boolean
|
||||||
default: false
|
|
||||||
saves_to_disk:
|
saves_to_disk:
|
||||||
required: true
|
required: true
|
||||||
type: boolean
|
type: boolean
|
||||||
|
|
|
@ -215,3 +215,17 @@ jobs:
|
||||||
saves_to_disk: true
|
saves_to_disk: true
|
||||||
disk_suffix: tip
|
disk_suffix: tip
|
||||||
height_grep_text: 'finished initial sync to chain tip, using gossiped blocks sync_percent=100.* current_height=Height'
|
height_grep_text: 'finished initial sync to chain tip, using gossiped blocks sync_percent=100.* current_height=Height'
|
||||||
|
|
||||||
|
lightwalletd-rpc-test:
|
||||||
|
if: ${{ github.event.inputs.regenerate-disks != 'true' }}
|
||||||
|
needs: build
|
||||||
|
uses: ./.github/workflows/gcp-test-deploy.yml
|
||||||
|
with:
|
||||||
|
app_name: lightwalletd
|
||||||
|
test_id: fully-synced-rpc
|
||||||
|
test_description: Test lightwalletd RPC with a Zebra tip state
|
||||||
|
test_variables: '-e TEST_LWD_RPC_CALL=1 -e ZEBRA_TEST_LIGHTWALLETD=1 -e ZEBRA_FORCE_USE_COLOR=1 -e ZEBRA_CACHED_STATE_DIR=/var/cache/zebrad-cache'
|
||||||
|
needs_zebra_state: true
|
||||||
|
saves_to_disk: false
|
||||||
|
disk_suffix: tip
|
||||||
|
zebra_state_path: '/var/cache'
|
||||||
|
|
|
@ -57,6 +57,9 @@ ENV RUST_LIB_BACKTRACE ${RUST_LIB_BACKTRACE:-0}
|
||||||
ARG COLORBT_SHOW_HIDDEN
|
ARG COLORBT_SHOW_HIDDEN
|
||||||
ENV COLORBT_SHOW_HIDDEN ${COLORBT_SHOW_HIDDEN:-0}
|
ENV COLORBT_SHOW_HIDDEN ${COLORBT_SHOW_HIDDEN:-0}
|
||||||
|
|
||||||
|
ARG RUST_LOG
|
||||||
|
ENV RUST_LOG ${RUST_LOG:-info}
|
||||||
|
|
||||||
# Skip IPv6 tests by default, as some CI environment don't have IPv6 available
|
# Skip IPv6 tests by default, as some CI environment don't have IPv6 available
|
||||||
ARG ZEBRA_SKIP_IPV6_TESTS
|
ARG ZEBRA_SKIP_IPV6_TESTS
|
||||||
ENV ZEBRA_SKIP_IPV6_TESTS ${ZEBRA_SKIP_IPV6_TESTS:-1}
|
ENV ZEBRA_SKIP_IPV6_TESTS ${ZEBRA_SKIP_IPV6_TESTS:-1}
|
||||||
|
|
|
@ -2,21 +2,6 @@
|
||||||
|
|
||||||
set -x
|
set -x
|
||||||
|
|
||||||
if [ ! -f /app/zebrad.toml ]; then
|
|
||||||
echo "
|
|
||||||
[consensus]
|
|
||||||
checkpoint_sync = ${CHECKPOINT_SYNC}
|
|
||||||
[metrics]
|
|
||||||
endpoint_addr = 0.0.0.0:9999
|
|
||||||
[network]
|
|
||||||
network = ${NETWORK}
|
|
||||||
[state]
|
|
||||||
cache_dir = /zebrad-cache
|
|
||||||
[tracing]
|
|
||||||
force_use_color = true
|
|
||||||
endpoint_addr = 0.0.0.0:3000" > /app/zebrad.toml
|
|
||||||
fi
|
|
||||||
|
|
||||||
case "$1" in
|
case "$1" in
|
||||||
-- | cargo)
|
-- | cargo)
|
||||||
if [[ "$RUN_ALL_TESTS" -eq "1" ]]; then
|
if [[ "$RUN_ALL_TESTS" -eq "1" ]]; then
|
||||||
|
@ -27,6 +12,8 @@ case "$1" in
|
||||||
exec cargo "test" "--locked" "--release" "--features" "enable-sentry,test_sync_to_mandatory_checkpoint_${NETWORK,,}" "--manifest-path" "zebrad/Cargo.toml" "sync_to_mandatory_checkpoint_${NETWORK,,}"
|
exec cargo "test" "--locked" "--release" "--features" "enable-sentry,test_sync_to_mandatory_checkpoint_${NETWORK,,}" "--manifest-path" "zebrad/Cargo.toml" "sync_to_mandatory_checkpoint_${NETWORK,,}"
|
||||||
elif [[ "$TEST_CHECKPOINT_SYNC" -eq "1" ]]; then
|
elif [[ "$TEST_CHECKPOINT_SYNC" -eq "1" ]]; then
|
||||||
exec cargo "test" "--locked" "--release" "--features" "enable-sentry,test_sync_past_mandatory_checkpoint_${NETWORK,,}" "--manifest-path" "zebrad/Cargo.toml" "sync_past_mandatory_checkpoint_${NETWORK,,}"
|
exec cargo "test" "--locked" "--release" "--features" "enable-sentry,test_sync_past_mandatory_checkpoint_${NETWORK,,}" "--manifest-path" "zebrad/Cargo.toml" "sync_past_mandatory_checkpoint_${NETWORK,,}"
|
||||||
|
elif [[ "$TEST_LWD_RPC_CALL" -eq "1" ]]; then
|
||||||
|
exec cargo "test" "--locked" "--release" "--features" "enable-sentry" "--test" "acceptance" "--" "--nocapture" "--ignored" "fully_synced_rpc_test"
|
||||||
else
|
else
|
||||||
exec "$@"
|
exec "$@"
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in New Issue