From cdd846efdc60741f80c9ac9bb47b89788a356357 Mon Sep 17 00:00:00 2001 From: teor Date: Mon, 1 Aug 2022 16:21:08 +1000 Subject: [PATCH] Skip RPC tests that require the network when ZEBRA_SKIP_NETWORK_TESTS is set (#4849) --- zebrad/tests/acceptance.rs | 4 ++++ zebrad/tests/common/lightwalletd/send_transaction_test.rs | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/zebrad/tests/acceptance.rs b/zebrad/tests/acceptance.rs index 95890d0fcd2..c1fd951cee3 100644 --- a/zebrad/tests/acceptance.rs +++ b/zebrad/tests/acceptance.rs @@ -1287,6 +1287,10 @@ async fn lightwalletd_test_suite() -> Result<()> { fn lightwalletd_integration_test(test_type: LightwalletdTestType) -> Result<()> { zebra_test::init(); + if zebra_test::net::zebra_skip_network_tests() { + return Ok(()); + } + // Skip the test unless the user specifically asked for it // // TODO: pass test_type to zebra_skip_lightwalletd_tests() and check for lightwalletd launch in there diff --git a/zebrad/tests/common/lightwalletd/send_transaction_test.rs b/zebrad/tests/common/lightwalletd/send_transaction_test.rs index 7578f9f2940..9f01de2cb86 100644 --- a/zebrad/tests/common/lightwalletd/send_transaction_test.rs +++ b/zebrad/tests/common/lightwalletd/send_transaction_test.rs @@ -46,6 +46,10 @@ use crate::common::{ pub async fn run() -> Result<()> { zebra_test::init(); + if zebra_test::net::zebra_skip_network_tests() { + return Ok(()); + } + // Skip the test unless the user specifically asked for it if zebra_skip_lightwalletd_tests() { return Ok(());