Skip to content

Commit 400097b

Browse files
committed
chore: add app status check in nightly
1 parent 13b89e6 commit 400097b

1 file changed

Lines changed: 16 additions & 2 deletions

File tree

test/specs/mainnet/ln.e2e.ts

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,15 @@ import {
66
restoreWallet,
77
tap,
88
sleep,
9+
expectTextWithin,
10+
doNavigationClose,
911
} from '../../helpers/actions';
1012
import { ciIt } from '../../helpers/suite';
1113

12-
const PAYMENT_TIMEOUT_MS = 300_000;
14+
const PAYMENT_TIMEOUT_MS = 90_000;
1315
const WALLET_SYNC_TIMEOUT_MS = 90_000;
14-
const SCREEN_TRANSITION_TIMEOUT_MS = 60_000;
16+
const APP_STATUS_ROW_TIMEOUT_MS = 90_000;
17+
const SCREEN_TRANSITION_TIMEOUT_MS = 30_000;
1518
const LN_STABILIZE_DELAY_MS = 10_000;
1619

1720
const ERROR_TOASTS = ['PaymentFailedToast', 'ExpiredLightningToast', 'InsufficientSpendingToast'];
@@ -64,6 +67,17 @@ async function waitForWalletReady(): Promise<void> {
6467
await elementById('TotalBalance-primary').waitForDisplayed({ timeout: WALLET_SYNC_TIMEOUT_MS });
6568
console.info('→ [LN] Home screen ready, letting LN node stabilize...');
6669
await sleep(LN_STABILIZE_DELAY_MS);
70+
console.info('→ [LN] Verify app status is ready');
71+
await tap('HeaderMenu');
72+
await tap('DrawerAppStatus');
73+
74+
await expectTextWithin('Status-internet', 'Connected', { timeout: APP_STATUS_ROW_TIMEOUT_MS });
75+
await expectTextWithin('Status-electrum', 'Connected', { timeout: APP_STATUS_ROW_TIMEOUT_MS });
76+
await expectTextWithin('Status-lightning_node', 'Running', { timeout: APP_STATUS_ROW_TIMEOUT_MS });
77+
await expectTextWithin('Status-lightning_connection', 'Open', { timeout: APP_STATUS_ROW_TIMEOUT_MS });
78+
79+
await doNavigationClose();
80+
console.info('→ [LN] App status verified');
6781
}
6882

6983
async function waitForAmountScreen(): Promise<void> {

0 commit comments

Comments
 (0)