diff --git a/integration_test/guide_shots_test.dart b/integration_test/guide_shots_test.dart index 400cf3b..77c88fe 100644 --- a/integration_test/guide_shots_test.dart +++ b/integration_test/guide_shots_test.dart @@ -40,6 +40,7 @@ import 'package:shared_preferences/shared_preferences.dart'; import 'package:chain_client_sdk/chain_client_sdk.dart' show HubEndpoint; import 'package:chain_studio/data/hub.dart'; import 'package:chain_studio/main.dart'; +import 'package:chain_studio/widgets/hub_auth_policy_panel.dart'; import 'package:chain_studio/widgets/widgets.dart'; import '../test/integration/hub_fixture.dart'; @@ -263,5 +264,29 @@ void main() { await tester.sendKeyEvent(LogicalKeyboardKey.escape); // settings too await _pumpFrames(tester, 5); } + + // Proof shot (not in the guide's image set, hence env-gated — + // the regen script keeps its stable 01–11 output): Settings → + // Security with the live auth-policy panel loaded from the + // fixture hub. + if (Platform.environment['GUIDE_SHOTS_SECURITY'] == '1') { + await tester.sendKeyEvent(LogicalKeyboardKey.escape); + await _pumpFrames(tester, 5); + ChainSettingsDialog.show(tester.element(find.byType(StudioShell))); + await _pumpFrames(tester); + final securityTab = find.text( + _locale.languageCode == 'en' ? 'Security' : 'Sicherheit', + ); + await _pumpUntil(tester, securityTab); + await tester.tap(securityTab.first); + await _pumpFrames(tester); + final policyPanel = find.byType(HubAuthPolicyPanel); + await _pumpUntil(tester, policyPanel); + await tester.ensureVisible(policyPanel.first); + await _pumpFrames(tester, 10); + await _shot(tester, '12-sicherheit'); + await tester.sendKeyEvent(LogicalKeyboardKey.escape); + await _pumpFrames(tester, 5); + } }); }