diff --git a/integration_test/components/common_test_cases.dart b/integration_test/components/common_test_cases.dart index c8f9843a6..e17fd5eb8 100644 --- a/integration_test/components/common_test_cases.dart +++ b/integration_test/components/common_test_cases.dart @@ -14,12 +14,25 @@ class CommonTestCases { String key, { bool shouldPumpAndSettle = true, int pumpDuration = 100, + Duration timeout = const Duration(seconds: 20), }) async { - await tester.pump(Duration(milliseconds: 500)); - final widgetFinder = find.byKey(ValueKey(key)); - expect(tester.any(widgetFinder), true, reason: 'Widget with key "$key" should be visible'); + // Wait for the widget to actually appear rather than pumping a flat 500ms + // and hoping. Screens that arrive behind an async transition (PIN setup's + // success button is the usual offender) are otherwise a coin flip, and the + // failure reads as "key missing" rather than "key not there YET". + // + // Deliberately a pump loop, not pumpAndSettle: the dashboard runs a + // perpetual sync-indicator animation, so settling never completes there. + final deadline = DateTime.now().add(timeout); + while (!tester.any(widgetFinder) && DateTime.now().isBefore(deadline)) { + await tester.pump(const Duration(milliseconds: 100)); + } + + expect(tester.any(widgetFinder), true, + reason: 'Widget with key "$key" should be visible ' + '(waited ${timeout.inSeconds}s)'); final widget = widgetFinder.first; await tester.tap(widget, warnIfMissed: false); diff --git a/integration_test/components/common_test_constants.dart b/integration_test/components/common_test_constants.dart index f26254401..441b10f21 100644 --- a/integration_test/components/common_test_constants.dart +++ b/integration_test/components/common_test_constants.dart @@ -6,10 +6,13 @@ class CommonTestConstants { static final String sendTestAmount = '0.00008'; static final String sendTestFiatAmount = '1.00'; static final String exchangeTestAmount = '0.01'; - static final WalletType testWalletType = WalletType.solana; + // Hash Bags is Wownero-first and no longer ships Solana, so the defaults + // moved off SOL. WalletType.solana does not exist in this fork. + static final WalletType testWalletType = WalletType.wownero; static final String testWalletName = 'Integrated Testing Wallet'; - static final CryptoCurrency sendTestReceiveCurrency = CryptoCurrency.sol; - static final CryptoCurrency exchangeTestReceiveCurrency = CryptoCurrency.usdtSol; - static final CryptoCurrency exchangeTestDepositCurrency = CryptoCurrency.sol; - static final String testWalletAddress = '7TSTXnQZxQDA4JoNqs4DqVqE7oNWk2kmHkMT6DD6vw2S'; + static final CryptoCurrency sendTestReceiveCurrency = CryptoCurrency.wow; + static final CryptoCurrency exchangeTestReceiveCurrency = CryptoCurrency.btc; + static final CryptoCurrency exchangeTestDepositCurrency = CryptoCurrency.wow; + static final String testWalletAddress = + 'Wo3MWeKwtA918DU4c69hVSNgejdWFCRCuWjShRY66mJkU2Hv58eygJWDJS1MNa2Ge5M1WjUkGHJLAjaZYLBZnDh42Q2u1Es9J'; } diff --git a/integration_test/components/common_test_flows.dart b/integration_test/components/common_test_flows.dart index f9727f5a9..0821e0dd2 100644 --- a/integration_test/components/common_test_flows.dart +++ b/integration_test/components/common_test_flows.dart @@ -352,30 +352,21 @@ class CommonTestFlows { return secrets.bitcoinCashTestWalletSeeds; case WalletType.polygon: return secrets.polygonTestWalletSeeds; - case WalletType.solana: - return secrets.solanaTestWalletSeeds; case WalletType.base: return secrets.baseTestWalletSeeds; case WalletType.arbitrum: return secrets.arbitrumTestWalletSeeds; case WalletType.bsc: return secrets.bscTestWalletSeeds; - case WalletType.tron: - return secrets.tronTestWalletSeeds; case WalletType.nano: return secrets.nanoTestWalletSeeds; case WalletType.wownero: return secrets.wowneroTestWalletSeeds; - case WalletType.zano: - return secrets.zanoTestWalletSeeds; - case WalletType.decred: - return secrets.decredTestWalletSeeds; + // Hash Bags does not ship SOL/TRX/ZEC/DCR/ZANO/Haven — those WalletType + // members no longer exist. dogecoin ships, but has no test seed in + // .secrets.g.dart. case WalletType.dogecoin: - return secrets.dogeTestWalletSeeds; - case WalletType.zcash: - return secrets.zcashTestWalletSeeds; case WalletType.none: - case WalletType.haven: case WalletType.banano: throw Exception("Unable to get seeds for ${walletType}"); } @@ -402,10 +393,6 @@ class CommonTestFlows { return secrets.arbitrumTestWalletReceiveAddress; case WalletType.bsc: return secrets.bscTestWalletReceiveAddress; - case WalletType.solana: - return secrets.solanaTestWalletReceiveAddress; - case WalletType.tron: - return secrets.tronTestWalletReceiveAddress; case WalletType.nano: return secrets.nanoTestWalletReceiveAddress; case WalletType.wownero: diff --git a/integration_test/robots/wallet_keys_robot.dart b/integration_test/robots/wallet_keys_robot.dart index 1c34e3577..ffd77c3f5 100644 --- a/integration_test/robots/wallet_keys_robot.dart +++ b/integration_test/robots/wallet_keys_robot.dart @@ -64,9 +64,9 @@ class WalletKeysAndSeedPageRobot { tester.printToConsole('$walletName wallet has seeds properly displayed'); } - if (isEVMCompatibleChain(walletType) || - walletType == WalletType.solana || - walletType == WalletType.tron) { + // Hash Bags does not ship Solana or Tron; those WalletType members were + // removed with the chains, so only the EVM chains remain here. + if (isEVMCompatibleChain(walletType)) { if (hasSeed) { final seedWords = appStore.wallet!.seed!.split(" "); for (var seedWord in seedWords) {