-
Notifications
You must be signed in to change notification settings - Fork 51
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
30 changed files
with
537 additions
and
460 deletions.
There are no files selected for viewing
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,45 @@ | ||
import 'package:flutter/material.dart'; | ||
import 'package:flutter_test/flutter_test.dart'; | ||
import 'package:integration_test/integration_test.dart'; | ||
import 'main.dart' as app; | ||
|
||
void main() { | ||
group('Testing App Performance Tests', () { | ||
final binding = IntegrationTestWidgetsFlutterBinding.ensureInitialized() as IntegrationTestWidgetsFlutterBinding; | ||
|
||
binding.framePolicy = LiveTestWidgetsFlutterBindingFramePolicy.fullyLive; | ||
|
||
testWidgets('starts with topRated', (tester) async { | ||
app.main(); | ||
await tester.pumpAndSettle(); | ||
|
||
// Movie 1 | ||
final titleTextFinder1 = find.byKey(Key('1-title')); | ||
final overviewTextFinder1 = find.byKey(Key('1-overview')); | ||
final releaseTextFinder1 = find.byKey(Key('1-releaseDate')); | ||
// checking widget present or not | ||
expect(titleTextFinder1, findsOneWidget); | ||
expect(overviewTextFinder1, findsOneWidget); | ||
expect(releaseTextFinder1, findsOneWidget); | ||
|
||
// checking values | ||
expect((titleTextFinder1.evaluate().single.widget as Text).data, 'Fight Club'); | ||
expect((overviewTextFinder1.evaluate().single.widget as Text).data, 'Overview 1'); | ||
expect((releaseTextFinder1.evaluate().single.widget as Text).data, '1999-10-12'); | ||
|
||
// Movie 2 | ||
final titleTextFinder2 = find.byKey(Key('2-title')); | ||
final overviewTextFinder2 = find.byKey(Key('2-overview')); | ||
final releaseTextFinder2 = find.byKey(Key('2-releaseDate')); | ||
// checking widget present or not | ||
expect(titleTextFinder2, findsOneWidget); | ||
expect(overviewTextFinder2, findsOneWidget); | ||
expect(releaseTextFinder2, findsOneWidget); | ||
|
||
// checking values | ||
expect((titleTextFinder2.evaluate().single.widget as Text).data, 'Fight Club 2'); | ||
expect((overviewTextFinder2.evaluate().single.widget as Text).data, 'Overview 2'); | ||
expect((releaseTextFinder2.evaluate().single.widget as Text).data, '1999-10-20'); | ||
}); | ||
}); | ||
} |
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,3 @@ | ||
import 'package:integration_test/integration_test_driver.dart'; | ||
|
||
Future<void> main() => integrationDriver(); |
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 |
---|---|---|
@@ -1 +1,2 @@ | ||
#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" | ||
#include "Generated.xcconfig" |
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 |
---|---|---|
@@ -1 +1,2 @@ | ||
#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" | ||
#include "Generated.xcconfig" |
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
2 changes: 1 addition & 1 deletion
2
ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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
Oops, something went wrong.