Files
Daniel DimitrovandGitHub df14945a19 tests(mobile): add safe-shield tests (#6793)
* tests(mobile): add safe-shield tests

* fix(mobile): prettier

* fix(mobile): address PR feedback
2025-12-05 17:11:52 +01:00

68 lines
1.9 KiB
YAML

appId: ${APP_ID}
tags:
- transactions
- pending
- safe-shield
---
# ===========================================
# SafeShield: Approve (Malicious - PoS Dai Stablecoin)
# ===========================================
# Safe: 0x65e1Ff7e0901055B3bea7D8b3AF457a659714013 (Polygon)
# Expected widget: Risk detected (CRITICAL)
# - Verified contract (OK)
# - Malicious threat detected (CRITICAL)
# - Balance change: No balance change detected
# - Risk disclaimer required
- runFlow:
file: ../../../../utils/setup/app-start.yml
- tapOn:
id: 'e2eSafeShieldSafe'
- assertVisible:
id: 'pending-tx-list'
- runFlow:
file: ../../../../utils/components/pending-tx/tap-tx-card.yml
env:
WAIT_FOR: '.*Dai Stablecoin.*'
TAP_TEXT: '.*Dai Stablecoin.*'
- assertVisible: 'Confirm transaction'
# ===========================================
# SafeShield Widget
# ===========================================
- runFlow:
file: ../../../../utils/assertions/verify-safe-shield-widget.yml
env:
WIDGET_HEADER: 'Risk detected'
LABEL_1: 'Verified contract'
LABEL_2: 'Malicious threat detected'
VERIFY_DISCLAIMER: 'true'
# ===========================================
# Balance Change Block
# ===========================================
- runFlow:
file: ../../../../utils/assertions/verify-balance-change.yml
env:
NO_CHANGE: 'true'
# ===========================================
# SafeShield Details Sheet
# ===========================================
- runFlow:
file: ../../../../utils/assertions/verify-safe-shield-sheet.yml
env:
TAP_TO_OPEN: 'Risk detected'
HEADER: 'RISK DETECTED'
LABEL_1: 'Verified contract'
DESCRIPTION_1: '.*verified as.*'
LABEL_2: 'Malicious threat detected'
DESCRIPTION_2: '.*known drainer contract.*'
# Verify back on Confirm transaction screen
- assertVisible: 'Confirm transaction'