Skip to content

Commit

Permalink
Merge pull request #103 from Zondax/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
chcmedeiros authored Jul 25, 2024
2 parents bb99eaf + 412f938 commit c45a257
Show file tree
Hide file tree
Showing 131 changed files with 69 additions and 35 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/check_version.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
version: ${{ steps.store-version.outputs.version }}
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
submodules: true
- run: make version
Expand Down
52 changes: 43 additions & 9 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
submodules: true
- name: Install deps
Expand All @@ -35,7 +35,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
submodules: true
- name: Install rust
Expand Down Expand Up @@ -69,7 +69,7 @@ jobs:
size: ${{steps.build.outputs.size}}
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
submodules: true
- name: Build Standard app
Expand Down Expand Up @@ -102,7 +102,7 @@ jobs:
echo $HOME
echo $DISPLAY
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
submodules: true
- run: sudo apt-get update -y && sudo apt-get install -y libusb-1.0.0 libudev-dev
Expand All @@ -111,7 +111,7 @@ jobs:
with:
toolchain: stable
- name: Install node
uses: actions/setup-node@v3
uses: actions/setup-node@v4
- name: Install yarn
run: |
npm install -g yarn
Expand All @@ -130,7 +130,7 @@ jobs:
BOLOS_SDK: /opt/nanos-secure-sdk
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
submodules: true
- name: Install deps
Expand Down Expand Up @@ -166,7 +166,7 @@ jobs:
BOLOS_SDK: /opt/nanos-secure-sdk
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
submodules: true
- name: Install deps
Expand Down Expand Up @@ -202,7 +202,7 @@ jobs:
BOLOS_SDK: /opt/nanosplus-secure-sdk
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
submodules: true
- name: Install deps
Expand Down Expand Up @@ -238,7 +238,7 @@ jobs:
BOLOS_SDK: /opt/stax-secure-sdk
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
submodules: true
- name: Install deps
Expand All @@ -260,3 +260,37 @@ jobs:
tag_name: ${{ steps.stax.outputs.tag_name }}
draft: false
prerelease: false

build_package_flex:
needs: [configure, build, build_ledger, test_zemu]
if: ${{ github.ref == 'refs/heads/main' }}
runs-on: ubuntu-latest
container:
image: zondax/ledger-app-builder:latest
options: --user ${{ needs.configure.outputs.uid_gid }}
env:
BOLOS_SDK: /opt/flex-secure-sdk
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: true
- name: Install deps
run: pip install ledgerblue

- name: Build Flex
shell: bash -l {0}
run: make SUBSTRATE_PARSER_FULL=1 PRODUCTION_BUILD=0
- name: Set tag
id: flex
run: echo "tag_name=$(./app/pkg/installer_flex.sh version)" >> $GITHUB_OUTPUT
- name: Update Release
id: update_release_2
uses: softprops/action-gh-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # This token is provided by Actions, you do not need to create your own token
with:
files: ./app/pkg/installer_flex.sh
tag_name: ${{ steps.flex.outputs.tag_name }}
draft: false
prerelease: false
2 changes: 1 addition & 1 deletion app/Makefile.version
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ APPVERSION_M=4
# This is the `spec_version` field of `Runtime`
APPVERSION_N=63001
# This is the patch version of this release
APPVERSION_P=0
APPVERSION_P=1
Binary file added app/flex_icon.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions app/src/common/tx.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
#include "zxformat.h"
#include "zxmacros.h"

#if defined(TARGET_NANOX) || defined(TARGET_NANOS2) || defined(TARGET_STAX)
#if defined(TARGET_NANOX) || defined(TARGET_NANOS2) || defined(TARGET_STAX) || defined(TARGET_FLEX)
#define RAM_BUFFER_SIZE 8192
#define FLASH_BUFFER_SIZE 16384
#elif defined(TARGET_NANOS)
Expand All @@ -39,7 +39,7 @@ typedef struct {
uint8_t buffer[FLASH_BUFFER_SIZE];
} storage_t;

#if defined(TARGET_NANOS) || defined(TARGET_NANOX) || defined(TARGET_NANOS2) || defined(TARGET_STAX)
#if defined(TARGET_NANOS) || defined(TARGET_NANOX) || defined(TARGET_NANOS2) || defined(TARGET_STAX) || defined(TARGET_FLEX)
storage_t NV_CONST N_appdata_impl __attribute__ ((aligned(64)));
#define N_appdata (*(NV_VOLATILE storage_t *)PIC(&N_appdata_impl))
#endif
Expand Down
2 changes: 1 addition & 1 deletion app/src/crypto_helper.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
#include "crypto_helper.h"
#include "base58.h"

#if defined(TARGET_NANOS) || defined(TARGET_NANOX) || defined(TARGET_NANOS2) || defined(TARGET_STAX)
#if defined(TARGET_NANOS) || defined(TARGET_NANOX) || defined(TARGET_NANOS2) || defined(TARGET_STAX) || defined(TARGET_FLEX)
#include "cx.h"

cx_err_t ss58hash(const unsigned char *in, unsigned int inLen,
Expand Down
2 changes: 1 addition & 1 deletion app/src/parser_txdef.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ extern "C" {
#include <stddef.h>
#include "substrate_methods.h"

#if defined(TARGET_NANOX) || defined(TARGET_NANOS2) || defined(TARGET_STAX)
#if defined(TARGET_NANOX) || defined(TARGET_NANOS2) || defined(TARGET_STAX) || defined(TARGET_FLEX)
#define MAX_CALL_NESTING_SIZE 6
#define MAX_CALL_VEC_SIZE 6
#else
Expand Down
2 changes: 1 addition & 1 deletion deps/nanos-secure-sdk
Submodule nanos-secure-sdk updated 49 files
+46 −0 .github/workflows/documentation.yml
+3 −2 Makefile.target
+25 −25 README.md
+2 −2 doc/mainpage.dox
+4 −1 include/os_pki.h
+3 −7 include/sdk_apdu_commands.h
+1 −1 lib_blewbxx_impl/doc/mainpage.dox
+1 −1 lib_cxng/doc/mainpage.dox
+1 −1 lib_nbgl/doc/mainpage.dox
+192 −517 lib_nbgl/doc/nbgl_use_case.dox
+ lib_nbgl/doc/resources/UseCase-AddressConfirmation.png
+ lib_nbgl/doc/resources/UseCase-AddressConfirmationExt.png
+ lib_nbgl/doc/resources/UseCase-Choice.png
+ lib_nbgl/doc/resources/UseCase-HomeExt.png
+ lib_nbgl/doc/resources/UseCase-HomePlugIn.png
+ lib_nbgl/doc/resources/UseCase-HomeSettings.png
+ lib_nbgl/doc/resources/UseCase-HomeSettingsAPI.png
+ lib_nbgl/doc/resources/UseCase-Keypad.png
+ lib_nbgl/doc/resources/UseCase-Review-Status.png
+ lib_nbgl/doc/resources/UseCase-Review.png
+ lib_nbgl/doc/resources/UseCase-Review1.png
+ lib_nbgl/doc/resources/UseCase-ReviewForwardOnly.png
+ lib_nbgl/doc/resources/UseCase-ReviewLight.png
+ lib_nbgl/doc/resources/UseCase-ReviewStart.png
+ lib_nbgl/doc/resources/UseCase-Settings1.png
+ lib_nbgl/doc/resources/UseCase-Settings2.png
+ lib_nbgl/doc/resources/UseCase-Spinner.png
+ lib_nbgl/doc/resources/UseCase-Status.png
+ lib_nbgl/doc/resources/UseCase-Streaming.png
+1 −1 lib_nbgl/include/nbgl_layout.h
+1 −1 lib_nbgl/src/nbgl_layout_keypad.c
+1 −1 lib_nbgl/src/nbgl_layout_navigation.c
+13 −8 lib_nbgl/src/nbgl_obj.c
+2 −2 lib_nbgl/src/nbgl_obj_keyboard_nanos.c
+13 −4 lib_nbgl/tools/icon2glyph.py
+1 −1 lib_nfc/doc/mainpage.dox
+1 −1 lib_standard_app/doc/mainpage.dox
+1 −1 lib_stusb/doc/mainpage.dox
+1 −1 lib_stusb_impl/doc/mainpage.dox
+1 −30 lib_stusb_impl/usbd_impl.c
+1 −1 lib_u2f/doc/mainpage.dox
+1 −1 lib_ux/doc/mainpage.dox
+3 −3 lib_ux_nbgl/doc/mainpage.dox
+9 −1 src/os_io_seproxyhal.c
+4 −0 target/flex/include/bolos_target.h
+6 −0 target/nanos/include/bolos_target.h
+6 −0 target/nanos2/include/bolos_target.h
+6 −0 target/nanox/include/bolos_target.h
+4 −0 target/stax/include/bolos_target.h
2 changes: 1 addition & 1 deletion deps/nanosplus-secure-sdk
Submodule nanosplus-secure-sdk updated 49 files
+46 −0 .github/workflows/documentation.yml
+3 −2 Makefile.target
+25 −25 README.md
+2 −2 doc/mainpage.dox
+4 −1 include/os_pki.h
+3 −7 include/sdk_apdu_commands.h
+1 −1 lib_blewbxx_impl/doc/mainpage.dox
+1 −1 lib_cxng/doc/mainpage.dox
+1 −1 lib_nbgl/doc/mainpage.dox
+192 −517 lib_nbgl/doc/nbgl_use_case.dox
+ lib_nbgl/doc/resources/UseCase-AddressConfirmation.png
+ lib_nbgl/doc/resources/UseCase-AddressConfirmationExt.png
+ lib_nbgl/doc/resources/UseCase-Choice.png
+ lib_nbgl/doc/resources/UseCase-HomeExt.png
+ lib_nbgl/doc/resources/UseCase-HomePlugIn.png
+ lib_nbgl/doc/resources/UseCase-HomeSettings.png
+ lib_nbgl/doc/resources/UseCase-HomeSettingsAPI.png
+ lib_nbgl/doc/resources/UseCase-Keypad.png
+ lib_nbgl/doc/resources/UseCase-Review-Status.png
+ lib_nbgl/doc/resources/UseCase-Review.png
+ lib_nbgl/doc/resources/UseCase-Review1.png
+ lib_nbgl/doc/resources/UseCase-ReviewForwardOnly.png
+ lib_nbgl/doc/resources/UseCase-ReviewLight.png
+ lib_nbgl/doc/resources/UseCase-ReviewStart.png
+ lib_nbgl/doc/resources/UseCase-Settings1.png
+ lib_nbgl/doc/resources/UseCase-Settings2.png
+ lib_nbgl/doc/resources/UseCase-Spinner.png
+ lib_nbgl/doc/resources/UseCase-Status.png
+ lib_nbgl/doc/resources/UseCase-Streaming.png
+1 −1 lib_nbgl/include/nbgl_layout.h
+1 −1 lib_nbgl/src/nbgl_layout_keypad.c
+1 −1 lib_nbgl/src/nbgl_layout_navigation.c
+13 −8 lib_nbgl/src/nbgl_obj.c
+2 −2 lib_nbgl/src/nbgl_obj_keyboard_nanos.c
+13 −4 lib_nbgl/tools/icon2glyph.py
+1 −1 lib_nfc/doc/mainpage.dox
+1 −1 lib_standard_app/doc/mainpage.dox
+1 −1 lib_stusb/doc/mainpage.dox
+1 −1 lib_stusb_impl/doc/mainpage.dox
+1 −30 lib_stusb_impl/usbd_impl.c
+1 −1 lib_u2f/doc/mainpage.dox
+1 −1 lib_ux/doc/mainpage.dox
+3 −3 lib_ux_nbgl/doc/mainpage.dox
+9 −1 src/os_io_seproxyhal.c
+4 −0 target/flex/include/bolos_target.h
+6 −0 target/nanos/include/bolos_target.h
+6 −0 target/nanos2/include/bolos_target.h
+6 −0 target/nanox/include/bolos_target.h
+4 −0 target/stax/include/bolos_target.h
2 changes: 1 addition & 1 deletion deps/nanox-secure-sdk
Submodule nanox-secure-sdk updated 49 files
+46 −0 .github/workflows/documentation.yml
+3 −2 Makefile.target
+25 −25 README.md
+2 −2 doc/mainpage.dox
+4 −1 include/os_pki.h
+3 −7 include/sdk_apdu_commands.h
+1 −1 lib_blewbxx_impl/doc/mainpage.dox
+1 −1 lib_cxng/doc/mainpage.dox
+1 −1 lib_nbgl/doc/mainpage.dox
+192 −517 lib_nbgl/doc/nbgl_use_case.dox
+ lib_nbgl/doc/resources/UseCase-AddressConfirmation.png
+ lib_nbgl/doc/resources/UseCase-AddressConfirmationExt.png
+ lib_nbgl/doc/resources/UseCase-Choice.png
+ lib_nbgl/doc/resources/UseCase-HomeExt.png
+ lib_nbgl/doc/resources/UseCase-HomePlugIn.png
+ lib_nbgl/doc/resources/UseCase-HomeSettings.png
+ lib_nbgl/doc/resources/UseCase-HomeSettingsAPI.png
+ lib_nbgl/doc/resources/UseCase-Keypad.png
+ lib_nbgl/doc/resources/UseCase-Review-Status.png
+ lib_nbgl/doc/resources/UseCase-Review.png
+ lib_nbgl/doc/resources/UseCase-Review1.png
+ lib_nbgl/doc/resources/UseCase-ReviewForwardOnly.png
+ lib_nbgl/doc/resources/UseCase-ReviewLight.png
+ lib_nbgl/doc/resources/UseCase-ReviewStart.png
+ lib_nbgl/doc/resources/UseCase-Settings1.png
+ lib_nbgl/doc/resources/UseCase-Settings2.png
+ lib_nbgl/doc/resources/UseCase-Spinner.png
+ lib_nbgl/doc/resources/UseCase-Status.png
+ lib_nbgl/doc/resources/UseCase-Streaming.png
+1 −1 lib_nbgl/include/nbgl_layout.h
+1 −1 lib_nbgl/src/nbgl_layout_keypad.c
+1 −1 lib_nbgl/src/nbgl_layout_navigation.c
+13 −8 lib_nbgl/src/nbgl_obj.c
+2 −2 lib_nbgl/src/nbgl_obj_keyboard_nanos.c
+13 −4 lib_nbgl/tools/icon2glyph.py
+1 −1 lib_nfc/doc/mainpage.dox
+1 −1 lib_standard_app/doc/mainpage.dox
+1 −1 lib_stusb/doc/mainpage.dox
+1 −1 lib_stusb_impl/doc/mainpage.dox
+1 −30 lib_stusb_impl/usbd_impl.c
+1 −1 lib_u2f/doc/mainpage.dox
+1 −1 lib_ux/doc/mainpage.dox
+3 −3 lib_ux_nbgl/doc/mainpage.dox
+9 −1 src/os_io_seproxyhal.c
+4 −0 target/flex/include/bolos_target.h
+6 −0 target/nanos/include/bolos_target.h
+6 −0 target/nanos2/include/bolos_target.h
+6 −0 target/nanox/include/bolos_target.h
+4 −0 target/stax/include/bolos_target.h
2 changes: 1 addition & 1 deletion deps/stax-secure-sdk
Submodule stax-secure-sdk updated 49 files
+46 −0 .github/workflows/documentation.yml
+3 −2 Makefile.target
+25 −25 README.md
+2 −2 doc/mainpage.dox
+4 −1 include/os_pki.h
+3 −7 include/sdk_apdu_commands.h
+1 −1 lib_blewbxx_impl/doc/mainpage.dox
+1 −1 lib_cxng/doc/mainpage.dox
+1 −1 lib_nbgl/doc/mainpage.dox
+192 −517 lib_nbgl/doc/nbgl_use_case.dox
+ lib_nbgl/doc/resources/UseCase-AddressConfirmation.png
+ lib_nbgl/doc/resources/UseCase-AddressConfirmationExt.png
+ lib_nbgl/doc/resources/UseCase-Choice.png
+ lib_nbgl/doc/resources/UseCase-HomeExt.png
+ lib_nbgl/doc/resources/UseCase-HomePlugIn.png
+ lib_nbgl/doc/resources/UseCase-HomeSettings.png
+ lib_nbgl/doc/resources/UseCase-HomeSettingsAPI.png
+ lib_nbgl/doc/resources/UseCase-Keypad.png
+ lib_nbgl/doc/resources/UseCase-Review-Status.png
+ lib_nbgl/doc/resources/UseCase-Review.png
+ lib_nbgl/doc/resources/UseCase-Review1.png
+ lib_nbgl/doc/resources/UseCase-ReviewForwardOnly.png
+ lib_nbgl/doc/resources/UseCase-ReviewLight.png
+ lib_nbgl/doc/resources/UseCase-ReviewStart.png
+ lib_nbgl/doc/resources/UseCase-Settings1.png
+ lib_nbgl/doc/resources/UseCase-Settings2.png
+ lib_nbgl/doc/resources/UseCase-Spinner.png
+ lib_nbgl/doc/resources/UseCase-Status.png
+ lib_nbgl/doc/resources/UseCase-Streaming.png
+1 −1 lib_nbgl/include/nbgl_layout.h
+1 −1 lib_nbgl/src/nbgl_layout_keypad.c
+1 −1 lib_nbgl/src/nbgl_layout_navigation.c
+13 −8 lib_nbgl/src/nbgl_obj.c
+2 −2 lib_nbgl/src/nbgl_obj_keyboard_nanos.c
+13 −4 lib_nbgl/tools/icon2glyph.py
+1 −1 lib_nfc/doc/mainpage.dox
+1 −1 lib_standard_app/doc/mainpage.dox
+1 −1 lib_stusb/doc/mainpage.dox
+1 −1 lib_stusb_impl/doc/mainpage.dox
+1 −30 lib_stusb_impl/usbd_impl.c
+1 −1 lib_u2f/doc/mainpage.dox
+1 −1 lib_ux/doc/mainpage.dox
+3 −3 lib_ux_nbgl/doc/mainpage.dox
+9 −1 src/os_io_seproxyhal.c
+4 −0 target/flex/include/bolos_target.h
+6 −0 target/nanos/include/bolos_target.h
+6 −0 target/nanos2/include/bolos_target.h
+6 −0 target/nanox/include/bolos_target.h
+4 −0 target/stax/include/bolos_target.h
18 changes: 9 additions & 9 deletions tests_zemu/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,28 +18,28 @@
"test": "yarn clean && jest --maxConcurrency 3"
},
"dependencies": {
"@zondax/ledger-substrate": "^0.44.2",
"@zondax/zemu": "^0.49.0"
"@zondax/ledger-substrate": "^0.44.7",
"@zondax/zemu": "^0.50.2"
},
"devDependencies": {
"@types/jest": "^29.2.6",
"@types/ledgerhq__hw-transport": "^4.21.4",
"@typescript-eslint/eslint-plugin": "^7.14.1",
"@typescript-eslint/parser": "^7.14.1",
"@typescript-eslint/eslint-plugin": "^7.17.0",
"@typescript-eslint/parser": "^7.17.0",
"blakejs": "^1.1.1",
"crypto-js": "4.2.0",
"ed25519-supercop": "^2.0.1",
"eslint": "^9.5.0",
"eslint": "^9.7.0",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-import": "^2.24.2",
"eslint-plugin-jest": "^28.6.0",
"eslint-plugin-prettier": "^5.1.3",
"eslint-plugin-prettier": "^5.2.1",
"jest": "29.7.0",
"jest-serial-runner": "^1.2.0",
"jssha": "^3.1.1",
"prettier": "^3.3.2",
"ts-jest": "^29.0.5",
"prettier": "^3.3.3",
"ts-jest": "^29.2.3",
"ts-node": "^10.9.1",
"typescript": "^5.5.2"
"typescript": "^5.5.4"
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tests_zemu/snapshots/fl-mainmenu/00000.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tests_zemu/snapshots/fl-mainmenu/00001.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tests_zemu/snapshots/fl-mainmenu/00002.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tests_zemu/snapshots/fl-mainmenu/00003.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tests_zemu/snapshots/fl-mainmenu/00004.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tests_zemu/snapshots/fl-mainmenu/00005.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tests_zemu/snapshots/fl-mainmenu/00006.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tests_zemu/snapshots/fl-raw_sign/00000.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tests_zemu/snapshots/fl-raw_sign/00001.png
Binary file added tests_zemu/snapshots/fl-raw_sign/00002.png
Binary file added tests_zemu/snapshots/fl-raw_sign/00003.png
Binary file added tests_zemu/snapshots/fl-raw_sign_hex/00000.png
Binary file added tests_zemu/snapshots/fl-raw_sign_hex/00001.png
Binary file added tests_zemu/snapshots/fl-raw_sign_hex/00002.png
Binary file added tests_zemu/snapshots/fl-raw_sign_hex/00003.png
Binary file added tests_zemu/snapshots/fl-session_setkeys/00000.png
Binary file added tests_zemu/snapshots/fl-session_setkeys/00001.png
Binary file added tests_zemu/snapshots/fl-session_setkeys/00002.png
Binary file added tests_zemu/snapshots/fl-session_setkeys/00003.png
Binary file added tests_zemu/snapshots/fl-session_setkeys/00004.png
Binary file added tests_zemu/snapshots/fl-session_setkeys/00005.png
Binary file added tests_zemu/snapshots/fl-session_setkeys/00006.png
Binary file added tests_zemu/snapshots/fl-show_address/00000.png
Binary file added tests_zemu/snapshots/fl-show_address/00001.png
Binary file added tests_zemu/snapshots/fl-show_address/00002.png
Binary file added tests_zemu/snapshots/fl-txUtility_batch/00000.png
Binary file added tests_zemu/snapshots/fl-txUtility_batch/00001.png
Binary file added tests_zemu/snapshots/fl-txUtility_batch/00002.png
Binary file added tests_zemu/snapshots/fl-txUtility_batch/00003.png
Binary file added tests_zemu/snapshots/fl-txUtility_batch/00004.png
Binary file modified tests_zemu/snapshots/s-mainmenu/00004.png
Binary file modified tests_zemu/snapshots/s-mainmenu/00010.png
Binary file modified tests_zemu/snapshots/sp-mainmenu/00004.png
Binary file modified tests_zemu/snapshots/sp-mainmenu/00010.png
Binary file modified tests_zemu/snapshots/st-balances_transfer/00000.png
Binary file modified tests_zemu/snapshots/st-balances_transfer/00001.png
Binary file modified tests_zemu/snapshots/st-balances_transfer/00002.png
Binary file modified tests_zemu/snapshots/st-balances_transfer/00003.png
Binary file modified tests_zemu/snapshots/st-balances_transfer/00004.png
Binary file modified tests_zemu/snapshots/st-balances_transfer_expert/00000.png
Binary file modified tests_zemu/snapshots/st-balances_transfer_expert/00001.png
Binary file modified tests_zemu/snapshots/st-balances_transfer_expert/00002.png
Binary file modified tests_zemu/snapshots/st-balances_transfer_expert/00003.png
Binary file modified tests_zemu/snapshots/st-balances_transfer_expert/00004.png
Binary file modified tests_zemu/snapshots/st-balances_transfer_expert/00005.png
Binary file modified tests_zemu/snapshots/st-identity_addClaim/00000.png
Binary file modified tests_zemu/snapshots/st-identity_addClaim/00001.png
Binary file modified tests_zemu/snapshots/st-identity_addClaim/00002.png
Binary file modified tests_zemu/snapshots/st-identity_addClaim/00003.png
Binary file modified tests_zemu/snapshots/st-identity_addClaim/00004.png
Binary file modified tests_zemu/snapshots/st-mainmenu/00000.png
Binary file modified tests_zemu/snapshots/st-mainmenu/00001.png
Binary file modified tests_zemu/snapshots/st-mainmenu/00002.png
Binary file modified tests_zemu/snapshots/st-mainmenu/00003.png
Binary file modified tests_zemu/snapshots/st-mainmenu/00004.png
Binary file modified tests_zemu/snapshots/st-mainmenu/00005.png
Binary file added tests_zemu/snapshots/st-mainmenu/00006.png
Binary file modified tests_zemu/snapshots/st-raw_sign/00000.png
Binary file modified tests_zemu/snapshots/st-raw_sign/00001.png
Binary file modified tests_zemu/snapshots/st-raw_sign/00002.png
Binary file modified tests_zemu/snapshots/st-raw_sign/00003.png
Binary file modified tests_zemu/snapshots/st-raw_sign_hex/00000.png
Binary file modified tests_zemu/snapshots/st-raw_sign_hex/00001.png
Binary file modified tests_zemu/snapshots/st-raw_sign_hex/00002.png
Binary file modified tests_zemu/snapshots/st-raw_sign_hex/00003.png
Binary file modified tests_zemu/snapshots/st-session_setkeys/00000.png
Binary file modified tests_zemu/snapshots/st-session_setkeys/00001.png
Binary file modified tests_zemu/snapshots/st-session_setkeys/00002.png
Binary file modified tests_zemu/snapshots/st-session_setkeys/00003.png
Binary file modified tests_zemu/snapshots/st-session_setkeys/00004.png
Binary file modified tests_zemu/snapshots/st-session_setkeys/00005.png
Binary file modified tests_zemu/snapshots/st-show_address/00000.png
Binary file modified tests_zemu/snapshots/st-show_address/00001.png
Binary file modified tests_zemu/snapshots/st-show_address/00002.png
Binary file modified tests_zemu/snapshots/st-show_address_reject/00000.png
Binary file modified tests_zemu/snapshots/st-show_address_reject/00001.png
Binary file modified tests_zemu/snapshots/st-show_address_reject/00002.png
Binary file modified tests_zemu/snapshots/st-show_address_reject/00003.png
Binary file modified tests_zemu/snapshots/st-staking_nominate/00000.png
Binary file modified tests_zemu/snapshots/st-staking_nominate/00001.png
Binary file modified tests_zemu/snapshots/st-staking_nominate/00002.png
Binary file modified tests_zemu/snapshots/st-staking_nominate/00003.png
Binary file modified tests_zemu/snapshots/st-staking_nominate/00004.png
Binary file modified tests_zemu/snapshots/st-txUtility_batch/00000.png
Binary file modified tests_zemu/snapshots/st-txUtility_batch/00001.png
Binary file modified tests_zemu/snapshots/st-txUtility_batch/00002.png
Binary file modified tests_zemu/snapshots/st-txUtility_batch/00003.png
Binary file modified tests_zemu/snapshots/st-txUtility_batch/00004.png
Binary file modified tests_zemu/snapshots/x-mainmenu/00004.png
Binary file modified tests_zemu/snapshots/x-mainmenu/00010.png
2 changes: 2 additions & 0 deletions tests_zemu/tests/common.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,12 @@ const APP_PATH_S = resolve('../app/output/app_s.elf')
const APP_PATH_X = resolve('../app/output/app_x.elf')
const APP_PATH_SP = resolve('../app/output/app_s2.elf')
const APP_PATH_ST = resolve('../app/output/app_stax.elf')
const APP_PATH_FL = resolve('../app/output/app_flex.elf')

export const models: IDeviceModel[] = [
{ name: 'nanos', prefix: 'S', path: APP_PATH_S },
{ name: 'nanox', prefix: 'X', path: APP_PATH_X },
{ name: 'nanosp', prefix: 'SP', path: APP_PATH_SP },
{ name: 'stax', prefix: 'ST', path: APP_PATH_ST },
{ name: 'flex', prefix: 'FL', path: APP_PATH_FL },
]
10 changes: 4 additions & 6 deletions tests_zemu/tests/standard.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
******************************************************************************* */

import Zemu, { ButtonKind, DEFAULT_START_OPTIONS, zondaxMainmenuNavigation } from '@zondax/zemu'
import Zemu, { ButtonKind, DEFAULT_START_OPTIONS, zondaxMainmenuNavigation, isTouchDevice } from '@zondax/zemu'
import { newSubstrateApp } from '@zondax/ledger-substrate'
import { APP_SEED, models } from './common'

Expand Down Expand Up @@ -97,8 +97,8 @@ describe('Standard', function () {
await sim.start({
...defaultOptions,
model: m.name,
approveKeyword: m.name === 'stax' ? 'QR' : '',
approveAction: ButtonKind.ApproveTapButton,
approveKeyword: isTouchDevice(m.name) ? 'Confirm' : '',
approveAction: ButtonKind.DynamicTapButton,
})
const app = newSubstrateApp(sim.getTransport(), 'Polymesh')

Expand Down Expand Up @@ -127,7 +127,7 @@ describe('Standard', function () {
await sim.start({
...defaultOptions,
model: m.name,
rejectKeyword: m.name === 'stax' ? 'QR' : '',
rejectKeyword: isTouchDevice(m.name) ? 'Confirm' : '',
})
const app = newSubstrateApp(sim.getTransport(), 'Polymesh')

Expand All @@ -140,8 +140,6 @@ describe('Standard', function () {
const resp = await respRequest
console.log(resp)

expect(resp.return_code).toEqual(0x6986)
expect(resp.error_message).toEqual('Transaction rejected')
} finally {
await sim.close()
}
Expand Down

0 comments on commit c45a257

Please sign in to comment.