-
Notifications
You must be signed in to change notification settings - Fork 1
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
Jeisson Andres Palacio Velasquez
committed
Oct 11, 2020
1 parent
d05ac3f
commit 466631d
Showing
9 changed files
with
157 additions
and
154 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 |
---|---|---|
|
@@ -35,6 +35,7 @@ dependencies: | |
|
||
|
||
|
||
|
||
dev_dependencies: | ||
flutter_driver: | ||
sdk: flutter | ||
|
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 @@ | ||
[{"description":"","id":"counter button","keyword":"Feature","line":1,"name":"Counter Button","uri":".\\test_driver\\features\\counter_button.feature","elements":[{"keyword":"Scenario","type":"scenario","id":"counter button;user taps on counter button","name":"User taps on counter button","description":"","line":7,"steps":[{"keyword":"Given ","name":"the user is at the counter dashboard","line":8,"match":{"location":".\\test_driver\\features\\counter_button.feature:8"},"result":{"status":"passed","duration":20000000}},{"keyword":"And ","name":"the counter value is at 0","line":9,"match":{"location":".\\test_driver\\features\\counter_button.feature:9"},"result":{"status":"failed","duration":0,"error_message":"GherkinStepNotDefinedException: Step definition not found for text:\n\n 'And the counter value is at 0'\n\n File path: .\\test_driver\\features\\counter_button.feature#8\n Line: And the counter value is at 0\n\n ---------------------------------------------\n\n You must implement the step like below and add the class to the 'stepDefinitions' property in your configuration:\n\n /// The 'Given' class prefix can be replaced with 'Then', 'When' 'And' or 'But'\n /// All classes can take up to 5 input parameters. With more, you should probably use a table.\n /// For example: `When4<String, bool, int, num>`\n /// You can also specify the type of world context you want\n /// `When4WithWorld<String, bool, int, num, MyWorld>`\n class Given_And_the_counter_value_is_at_0 extends Given1<String> {\n @override\n RegExp get pattern => RegExp(r\"the counter value is at 0\");\n\n @override\n Future<void> executeStep(String input1) async {\n // If the step is \"Given I do a 'windy pop'\"\n // in this example, input1 would equal 'windy pop'\n\n // your code...\n }\n }\n \n\n#0 FeatureFileRunner._matchStepToExecutableStep (package:gherkin/src/feature_file_runner.dart:390:7)\n#1 FeatureFileRunner._runStep (package:gherkin/src/feature_file_runner.dart:311:20)\n#2 _rootRunUnary (dart:async/zone.dart:1198:47)\n#3 _CustomZone.runUnary (dart:async/zone.dart:1100:19)\n#4 _FutureListener.handleValue (dart:async/future_impl.dart:143:18)\n#5 Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:696:45)\n#6 Future._propagateToListeners (dart:async/future_impl.dart:725:32)\n#7 Future._completeWithValue (dart:async/future_impl.dart:529:5)\n#8 _AsyncAwaitCompleter.complete (dart:async-patch/async_patch.dart:40:15)\n#9 _completeOnAsyncReturn (dart:async-patch/async_patch.dart:311:13)\n#10 AggregatedReporter.onStepStarted (package:gherkin/src/reporters/aggregated_reporter.dart)\n#11 _rootRunUnary (dart:async/zone.dart:1198:47)\n#12 _CustomZone.runUnary (dart:async/zone.dart:1100:19)\n#13 _FutureListener.handleValue (dart:async/future_impl.dart:143:18)\n#14 Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:696:45)\n#15 Future._propagateToListeners (dart:async/future_impl.dart:725:32)\n#16 Future._completeWithValue (dart:async/future_impl.dart:529:5)\n#17 _AsyncAwaitCompleter.complete (dart:async-patch/async_patch.dart:40:15)\n#18 _completeOnAsyncReturn (dart:async-patch/async_patch.dart:311:13)\n#19 AggregatedReporter._invokeReporters (package:gherkin/src/reporters/aggregated_reporter.dart)\n#20 _rootRunUnary (dart:async/zone.dart:1198:47)\n#21 _CustomZone.runUnary (dart:async/zone.dart:1100:19)\n#22 _FutureListener.handleValue (dart:async/future_impl.dart:143:18)\n#23 Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:696:45)\n#24 Future._propagateToListeners (dart:async/future_impl.dart:725:32)\n#25 Future._completeWithValue (dart:async/future_impl.dart:529:5)\n#26 _AsyncAwaitCompleter.complete (dart:async-patch/async_patch.dart:40:15)\n#27 _completeOnAsyncReturn (dart:async-patch/async_patch.dart:311:13)\n#28 AggregatedReporter.onStepStarted.<anonymous closure> (package:gherkin/src/reporters/aggregated_reporter.dart)\n#29 _rootRunUnary (dart:async/zone.dart:1198:47)\n#30 _CustomZone.runUnary (dart:async/zone.dart:1100:19)\n#31 _FutureListener.handleValue (dart:async/future_impl.dart:143:18)\n#32 Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:696:45)\n#33 Future._propagateToListeners (dart:async/future_impl.dart:725:32)\n#34 Future._completeWithValue (dart:async/future_impl.dart:529:5)\n#35 Future._asyncCompleteWithValue.<anonymous closure> (dart:async/future_impl.dart:567:7)\n#36 _rootRun (dart:async/zone.dart:1190:13)\n#37 _CustomZone.run (dart:async/zone.dart:1093:19)\n#38 _CustomZone.runGuarded (dart:async/zone.dart:997:7)\n#39 _CustomZone.bindCallbackGuarded.<anonymous closure> (dart:async/zone.dart:1037:23)\n#40 _microtaskLoop (dart:async/schedule_microtask.dart:41:21)\n#41 _startMicrotaskLoop (dart:async/schedule_microtask.dart:50:5)\n#42 _runPendingImmediateCallback (dart:isolate-patch/isolate_patch.dart:118:13)\n#43 _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:169:5)"}}]}]}] |
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,33 @@ | ||
import 'package:flutter/material.dart'; | ||
import 'package:flutter_svg/flutter_svg.dart'; | ||
import 'package:flutter_test/flutter_test.dart'; | ||
import 'package:project_test_unit/widgets/top_menu.dart'; | ||
|
||
main() { | ||
|
||
final MaterialApp app = MaterialApp( | ||
home: Scaffold( | ||
body: HomeHeader() | ||
), | ||
|
||
); | ||
|
||
|
||
testWidgets("Prueba Widget top menu", (WidgetTester test) async{ | ||
|
||
await test.pumpWidget(app); | ||
final imagenCar = find.byKey(Key('assets/icons/car2.svg')); | ||
final image = imagenCar.evaluate().single.widget as SvgPicture; | ||
|
||
expect((image.pictureProvider as ExactAssetImage).assetName, equals('assets/icons/car2.svg')); | ||
expect(find.text("Deportivo"), findsOneWidget); | ||
expect(find.byType(ListView),findsOneWidget); | ||
|
||
|
||
|
||
|
||
}); | ||
|
||
|
||
|
||
} |
This file was deleted.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,12 @@ | ||
import 'package:flutter_driver/driver_extension.dart'; | ||
import 'package:project_test_unit/main.dart' as app; | ||
|
||
void main() { | ||
enableFlutterDriverExtension(); | ||
app.main(); | ||
|
||
|
||
void main(){ | ||
|
||
enableFlutterDriverExtension(); | ||
app.main(); | ||
|
||
|
||
|
||
} |
Oops, something went wrong.