mirror of
https://github.com/luxfi/safe-wallet.git
synced 2026-11-02 06:23:25 +00:00
* feat(mobile): add stable per-transaction testID to transaction cards TxInfo now stamps every card it renders with testID="tx-card-<txId>" (caller-supplied testID wins), and the four card types that did not forward SafeListItemProps (StakingTxExit, StakingTxWithdraw, TxBridge, TxLifiSwap) now spread them like the rest. This lets E2E flows target a transaction by identity instead of list position, which breaks whenever the shared test Safe's queue drifts. * tests(mobile): target safe-shield tx by id instead of list position The shared test Safe's queue gained four conflicting nonce-3 transactions that all render as identical "Contract interaction" cards, so TAP_INDEX: 1 opened the wrong transaction. tap-tx-card now supports TAP_ID (scroll-until-visible + tap on the tx-card-<txId> testID) and the malicious contract-interaction flow uses it; the TAP_TEXT/TAP_INDEX path is unchanged for existing callers. * tests(mobile): make change-currency robust to backend list order The supported-fiat-codes endpoint now returns extra crypto tickers at the head of the list, pushing EUR/GBP below the fold and breaking the viewport assertions. Scroll to known entries in list order (USD, EUR, GBP) instead of asserting on the initial viewport. * tests(mobile): address review findings — order-independent flows - change-currency: use the currency search field instead of scroll order assumptions; dismiss the keyboard before tapping a row (first tap only closes the keyboard otherwise) and match full row labels so the search input's own text can't be tapped. - batch-3-actions-benign/-warn: migrate from TAP_INDEX to TAP_ID. - tap-tx-card: treat whitespace-only TAP_ID as unset. - TxInfo: document why the default testID precedes the props spread. --------- Co-authored-by: Hanzo Dev <[email protected]>
64 lines
2.1 KiB
YAML
64 lines
2.1 KiB
YAML
appId: ${APP_ID}
|
|
tags:
|
|
- safe-shield
|
|
- pending-tx
|
|
---
|
|
# ===========================================
|
|
# SafeShield Test: 3 Actions Batch (WARN)
|
|
# ===========================================
|
|
# Tests SafeShield functionality for a 3-action multiSend batch transaction
|
|
# with moderate threat detected (WARN severity).
|
|
|
|
# Launch app with SafeShield test safe
|
|
- runFlow:
|
|
file: '../../../../utils/setup/app-start.yml'
|
|
|
|
- tapOn:
|
|
id: 'e2eSafeShieldSafe'
|
|
|
|
- assertVisible:
|
|
id: 'pending-tx-list'
|
|
|
|
# 3-action batch with issues at nonce 20 — targeted by txId so queue reordering can't break it
|
|
- runFlow:
|
|
file: '../../../../utils/components/pending-tx/tap-tx-card.yml'
|
|
env:
|
|
TAP_ID: 'tx-card-multisig_0x65e1Ff7e0901055B3bea7D8b3AF457a659714013_0xbd43fc526d037c4b7de84a6eb10959a5590c3a77ce664e6924ee1e2ffef8e63e'
|
|
|
|
- assertVisible: 'Confirm transaction'
|
|
|
|
# Verify SafeShield widget (WARN severity - Issues found)
|
|
- runFlow:
|
|
file: '../../../../utils/assertions/verify-safe-shield-widget.yml'
|
|
env:
|
|
WIDGET_HEADER: 'Issues found'
|
|
LABEL_1: 'Verified contract'
|
|
LABEL_2: 'Moderate threat detected'
|
|
|
|
# Verify balance change block (no balance change)
|
|
- runFlow:
|
|
file: '../../../../utils/assertions/verify-balance-change.yml'
|
|
env:
|
|
NO_CHANGE: 'true'
|
|
|
|
# Open and verify SafeShield details sheet
|
|
- runFlow:
|
|
file: '../../../../utils/assertions/verify-safe-shield-sheet.yml'
|
|
env:
|
|
TAP_TO_OPEN: 'Issues found'
|
|
HEADER: 'ISSUES FOUND'
|
|
LABEL_1: 'Verified contract'
|
|
DESCRIPTION_1: '.*1 contract is verified.*'
|
|
DESCRIPTION_1_2: '.*You have interacted with 1 contract before.*'
|
|
EXPAND_SHOW_ALL: 'true'
|
|
EXPANDED_ADDRESS: '.*0x000000000000aDdB49795b0f9bA5BC298c.*'
|
|
EXPAND_SHOW_ALL_2: 'true'
|
|
EXPANDED_ADDRESS_2: '.*0x65e1Ff7e0901055B3bea7D8b3AF457a659714.*'
|
|
SCROLL_TO_FOOTER: 'true'
|
|
LABEL_2: 'Moderate threat detected'
|
|
DESCRIPTION_2: '.*The transaction enables an untrusted address as a module.*'
|
|
DESCRIPTION_2_2: '.*This address is untrusted.*'
|
|
|
|
# Verify we're back on the confirm transaction screen
|
|
- assertVisible: 'Confirm transaction'
|