From e22d5a7db40a3ba96ce246b5e013dfe413541f72 Mon Sep 17 00:00:00 2001 From: Caio Casimiro Date: Thu, 16 Nov 2023 10:50:57 +0000 Subject: [PATCH] chore(util/test.sh) conditionally build SDKs SDKs test files will have `language_sdk` as part of their name, e.g.: - `001-rust_sdk` - `002-go_sdk` - `003-assemblyscript_sdk` As such, filter examples from SDKs can be conditionally compiled based on the presence of the aforementioned patterns in the script parameters. --- util/test.sh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/util/test.sh b/util/test.sh index e1fc10cb5..93fb0fcbf 100755 --- a/util/test.sh +++ b/util/test.sh @@ -94,7 +94,13 @@ if [[ "$CI" == 'true' ]]; then export NGX_BUILD_FORCE=1 fi -$NGX_WASM_DIR/util/sdk.sh -S go --build +if [[ $PARAMS == *"assemblyscript_sdk"* ]]; then + $NGX_WASM_DIR/util/sdk.sh -S assemblyscript --build +fi + +if [[ $PARAMS == *"go_sdk"* ]]; then + $NGX_WASM_DIR/util/sdk.sh -S go --build +fi args=()