askrobots / dbbasic-scroll
Public
Scroll: the Flutter operator console for the DBBASIC Object Server, for people building alongside AI agents.
widget_test.dart · 540 bytes · 18 lines
| 1 | import 'package:flutter_test/flutter_test.dart'; |
| 2 | import 'package:shared_preferences/shared_preferences.dart'; |
| 3 | |
| 4 | import 'package:dbbasic_scroll/main.dart'; |
| 5 | |
| 6 | void main() { |
| 7 | testWidgets('shows connect screen when no saved connection', ( |
| 8 | WidgetTester tester, |
| 9 | ) async { |
| 10 | SharedPreferences.setMockInitialValues({}); |
| 11 | |
| 12 | await tester.pumpWidget(const ScrollApp()); |
| 13 | await tester.pumpAndSettle(); |
| 14 | |
| 15 | expect(find.text('DBBasic Scroll'), findsOneWidget); |
| 16 | expect(find.text('Connect to your object server'), findsOneWidget); |
| 17 | }); |
| 18 | } |