From 8c707d058610d4d7054e26738325650e07ee708c 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 | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/util/test.sh b/util/test.sh index e1fc10cb5..3c7165913 100755 --- a/util/test.sh +++ b/util/test.sh @@ -94,7 +94,14 @@ if [[ "$CI" == 'true' ]]; then export NGX_BUILD_FORCE=1 fi -$NGX_WASM_DIR/util/sdk.sh -S go --build +case "$PARAMS" in + *assemblyscript_sdk*) + $NGX_WASM_DIR/util/sdk.sh -S assemblyscript --build + ;; + *go_sdk*) + $NGX_WASM_DIR/util/sdk.sh -S go --build + ;; +esac args=()