mirror of
https://github.com/luxfi/safe-wallet.git
synced 2026-10-30 15:19:21 +00:00
121 lines
4.1 KiB
YAML
121 lines
4.1 KiB
YAML
appId: ${APP_ID}
|
|
tags:
|
|
- util
|
|
jsEngine: graaljs
|
|
---
|
|
# ===========================================
|
|
# Batch Transaction (Pending State)
|
|
# ===========================================
|
|
# Tests the batch transaction detail view for pending transactions
|
|
# Batch transactions (multiSend) cannot be executed until threshold is reached
|
|
#
|
|
# Environment variables:
|
|
# IS_EXECUTABLE: Whether the transaction is expected to be executable - "true" or "false"
|
|
# Defaults to "false" if not provided (threshold not reached)
|
|
# If "false": verifies that the threshold message is shown
|
|
# If "true": verifies that Continue button works and can proceed to review screen
|
|
|
|
- assertVisible: 'Confirm transaction'
|
|
|
|
# Verify the transaction method name is visible
|
|
- assertVisible:
|
|
text: 'multiSend'
|
|
|
|
# ===========================================
|
|
# Parse IS_EXECUTABLE environment variable
|
|
# ===========================================
|
|
# Parse the IS_EXECUTABLE environment variable using GraalJS
|
|
# Default to "false" (not executable) if not provided
|
|
- evalScript: '${output.isExecutable = (typeof IS_EXECUTABLE !== "undefined" && IS_EXECUTABLE === "true")}'
|
|
- evalScript: '${output.isNotExecutable = output.isExecutable === false}'
|
|
|
|
# ===========================================
|
|
# Network Display
|
|
# ===========================================
|
|
- runFlow:
|
|
file: ../../assertions/verify-tx-network.yml
|
|
|
|
# ===========================================
|
|
# Transaction Details Button
|
|
# ===========================================
|
|
- runFlow:
|
|
file: ../../assertions/verify-tx-details.yml
|
|
|
|
# ===========================================
|
|
# Actions Section
|
|
# ===========================================
|
|
# Verify Actions section is visible with action count
|
|
- assertVisible:
|
|
text: 'Actions'
|
|
|
|
# Verify the action count badge (e.g., "3")
|
|
- assertVisible:
|
|
text: '.*\d+.*'
|
|
|
|
# Tap on Actions to view the actions list
|
|
- tapOn:
|
|
text: 'Actions'
|
|
|
|
# Test the actions list using shared component
|
|
- runFlow:
|
|
file: ../../assertions/verify-actions-list.yml
|
|
|
|
# Go back from Actions screen to Confirm transaction
|
|
- tapOn:
|
|
id: 'go-back'
|
|
|
|
# Verify we're back on Confirm transaction screen
|
|
- assertVisible: 'Confirm transaction'
|
|
|
|
# ===========================================
|
|
# SafeShield Transaction Checks
|
|
# ===========================================
|
|
- runFlow:
|
|
file: ../../assertions/verify-tx-checks.yml
|
|
env:
|
|
WIDGET_HEADER_PATTERN: '.*(Review details|Issues found|Checks passed).*'
|
|
BALANCE_CHANGE_PATTERN: 'No balance change detected'
|
|
|
|
# ===========================================
|
|
# Confirmations
|
|
# ===========================================
|
|
# Test tapping on confirmations to open the bottom sheet and verify signed badge
|
|
# Verify that 1/2 confirmations are shown (threshold not reached)
|
|
# Scroll to make confirmations visible (SafeShield block takes more vertical space)
|
|
- scroll
|
|
- runFlow:
|
|
file: ../../assertions/verify-tx-confirmations.yml
|
|
env:
|
|
CONFIRMATIONS_PATTERN: '.*1/2.*'
|
|
|
|
# ===========================================
|
|
# Executability Check
|
|
# ===========================================
|
|
# If not executable, verify the threshold message
|
|
- runFlow:
|
|
when:
|
|
true: '${output.isNotExecutable === true}'
|
|
commands:
|
|
# Verify the threshold message is visible
|
|
- assertVisible:
|
|
text: '.*Can be executed once the threshold is reached.*'
|
|
|
|
# If executable, verify Continue button works and proceed to review screen
|
|
- runFlow:
|
|
when:
|
|
true: '${output.isExecutable === true}'
|
|
commands:
|
|
# Verify Continue button is visible (should not show threshold message)
|
|
- assertVisible:
|
|
text: 'Continue'
|
|
# Verify the threshold message is NOT visible when executable
|
|
- assertNotVisible:
|
|
text: '.*Can be executed once the threshold is reached.*'
|
|
# Test navigating to Review and execute screen
|
|
- runFlow:
|
|
file: ../../assertions/verify-review-and-execute.yml
|
|
env:
|
|
EXPECTED_SIGNER_PATTERN: '.*6fED.*'
|
|
IS_FULLY_SIGNED: 'true'
|
|
TX_EXECUTION_STATUS: 'succeed'
|