-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Revert "feat(#578): remove onboarding"
This reverts commit d3c9975.
- Loading branch information
Showing
18 changed files
with
3,539 additions
and
1 deletion.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
import 'package:app/common/module.dart'; | ||
import 'package:flutter_localizations/flutter_localizations.dart'; | ||
import 'package:flutter_test/flutter_test.dart'; | ||
import 'package:integration_test/integration_test.dart'; | ||
|
||
void main() { | ||
final binding = IntegrationTestWidgetsFlutterBinding.ensureInitialized(); | ||
|
||
binding.framePolicy = LiveTestWidgetsFlutterBindingFramePolicy.onlyPumps; | ||
|
||
group('integration tests for the onboarding', () { | ||
testWidgets('Test that pages are changing', (tester) async { | ||
final appRouter = AppRouter(); | ||
await tester.pumpWidget(MaterialApp.router( | ||
debugShowCheckedModeBanner: false, | ||
routeInformationParser: appRouter.defaultRouteParser(), | ||
routerDelegate: appRouter.delegate( | ||
initialDeepLink: 'onboarding', | ||
), | ||
localizationsDelegates: [ | ||
AppLocalizations.delegate, | ||
GlobalMaterialLocalizations.delegate, | ||
GlobalWidgetsLocalizations.delegate, | ||
GlobalCupertinoLocalizations.delegate, | ||
], | ||
supportedLocales: [Locale('en', '')], | ||
)); | ||
|
||
await tester.pumpAndSettle(); | ||
|
||
final BuildContext context = tester.element(find.byType(Scaffold).first); | ||
expect(find.text(context.l10n.onboarding_1_header), findsOneWidget); | ||
|
||
// change page | ||
await tester.tap(find.byKey(ValueKey('nextButton'))); | ||
await tester.pumpAndSettle(); | ||
expect(find.text(context.l10n.onboarding_2_header), findsOneWidget); | ||
// change page | ||
await tester.tap(find.byKey(ValueKey('nextButton'))); | ||
await tester.pumpAndSettle(); | ||
expect(find.text(context.l10n.onboarding_3_header), findsOneWidget); | ||
|
||
await tester.tap(find.byKey(ValueKey('nextButton'))); | ||
await tester.pumpAndSettle(); | ||
expect(find.text(context.l10n.onboarding_4_header), findsOneWidget); | ||
|
||
await tester.tap(find.byKey(ValueKey('nextButton'))); | ||
await tester.pumpAndSettle(); | ||
expect(find.text(context.l10n.onboarding_5_header), findsOneWidget); | ||
}); | ||
}); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
import '../common/module.dart'; | ||
import 'pages/onboarding.dart'; | ||
|
||
export 'pages/onboarding.dart'; | ||
|
||
const onboardingRoutes = AutoRoute( | ||
path: 'onboarding', | ||
name: 'OnboardingRouter', | ||
page: OnboardingPage, | ||
); |
Oops, something went wrong.