diff --git a/.github/workflows/main.yaml b/.github/workflows/main.yaml index 1ef020616..ffcabbb92 100644 --- a/.github/workflows/main.yaml +++ b/.github/workflows/main.yaml @@ -79,7 +79,7 @@ jobs: - varname: STAX_SDK target: stax container: - image: zondax/ledger-app-builder:latest + image: zondax/ledger-app-builder:ledger-d5bfe2e793f15a826971ae9de2adcad524df3e8e env: SDK_VARNAME: ${{ matrix.sdk.varname }} options: --user ${{ needs.configure.outputs.uid_gid }} diff --git a/Justfile b/Justfile index eb64b34bb..786e73ea1 100644 --- a/Justfile +++ b/Justfile @@ -52,3 +52,46 @@ cargo *cmd='': cargo {{cmd}} insta: (cargo "insta test --review") + +_ztest-ci: + #!/bin/env bash + pushd zemu + TESTS=`yarn test --listTests --json | head -n 3 | tail -n 1 | jq -r '.[]'` + + has_failed=0 + outputs=() + + for file in ${TESTS[@]}; do + output=`yarn jest "$file" --maxConcurrency 2 2>&1` + exit=$? + + outputs+=("$output") + if [ $exit -ne 0 ]; then + echo "=== Test $file failed ===" + has_failed=1 + fi + done + + if [ $has_failed -eq 1 ]; then + for i in "${!outputs[@]}"; do + output=$outputs[i] + file=$TESTS[i] + echo "=== Test Output for $file ===" + echo "$output" + done + echo "Some tests failed. See detailed output above." + exit 1 + else + echo "All tests passed." + exit 0 + fi + + popd + +# Run the same things as a normal CI workflow +ci: + just miri + cargo fmt -- --check + cargo clippy --all-targets --features "full" + just make clean all + just _ztest-ci diff --git a/app/Makefile b/app/Makefile index f1f698e1d..89efd3f2a 100755 --- a/app/Makefile +++ b/app/Makefile @@ -264,8 +264,6 @@ ifeq (,$(filter $(TARGET_NAME),TARGET_NANOS TARGET_STAX)) # mainnet or testnet. lets pick # the ones for mainnet for now DEFINES += BIP32_PUBKEY_VERSION=0x0488B21E - DEFINES += BIP44_COIN_TYPE=0 - DEFINES += BIP44_COIN_TYPE_2=0 # The coin type bellow is not part of the btc app, # but this is necesary here as avax wants support for # coin_type = 60' diff --git a/app/c/handler.c b/app/c/handler.c index 193a41f5d..6e5fa13c7 100644 --- a/app/c/handler.c +++ b/app/c/handler.c @@ -55,11 +55,6 @@ const command_descriptor_t COMMAND_DESCRIPTORS[] = { .ins = GET_WALLET_ADDRESS, .handler = (command_handler_t)handler_get_wallet_address }, - { - .cla = CLA_APP, - .ins = REGISTER_WALLET, - .handler = (command_handler_t)handler_register_wallet - }, { .cla = CLA_APP, .ins = SIGN_PSBT, diff --git a/deps/btc b/deps/btc index 4902a8c70..6748b6215 160000 --- a/deps/btc +++ b/deps/btc @@ -1 +1 @@ -Subproject commit 4902a8c70b4b4ea527c5917d9f9e2861d380d4e1 +Subproject commit 6748b621514f1188e778211f41a0a5c225d3f4e3 diff --git a/deps/dockerized_build.mk b/deps/dockerized_build.mk index 2c22f1b8d..5ffda177d 100644 --- a/deps/dockerized_build.mk +++ b/deps/dockerized_build.mk @@ -47,7 +47,7 @@ $(info TESTS_ZEMU_DIR : $(TESTS_ZEMU_DIR)) $(info TESTS_JS_DIR : $(TESTS_JS_DIR)) $(info TESTS_JS_PACKAGE : $(TESTS_JS_PACKAGE)) -DOCKER_IMAGE_ZONDAX=zondax/ledger-app-builder:latest +DOCKER_IMAGE_ZONDAX=zondax/ledger-app-builder:ledger-d5bfe2e793f15a826971ae9de2adcad524df3e8e DOCKER_IMAGE_LEDGER=ghcr.io/ledgerhq/ledger-app-builder/ledger-app-builder:latest ifdef INTERACTIVE diff --git a/zemu/package.json b/zemu/package.json index 227cacb94..549331505 100644 --- a/zemu/package.json +++ b/zemu/package.json @@ -18,7 +18,7 @@ "dependencies": { "@types/node": "^18.14.6", "@zondax/ledger-avalanche-app": "link:../js", - "@zondax/zemu": "^0.44.0" + "@zondax/zemu": "=0.44.0" }, "devDependencies": { "@ethereumjs/common": "^3.1.1",