mirror of
https://github.com/flutter/flutter.git
synced 2025-06-03 00:51:18 +00:00
![]() This adds a smoke test for every single API example. It also fixes 17 tests that had bugs in them, or were otherwise broken, and even fixes one actual bug in the framework, and one limitation in the framework. The bug in the framework is that NetworkImage's _loadAsync method had await response.drain<List<int>>();, but if the response is null, it will throw a cryptic exception saying that Null can't be assigned to List<int>. The fix was just to use await response.drain<void>(); instead. The limitation is that RelativePositionedTransition takes an Animation<Rect> rect parameter, and if you want to use a RectTween with it, the value emitted there is Rect?, and one of the examples was just casting from Animation<Rect> to Animation<Rect?>, which is invalid, so I modified RelativePositionedTransition to take a Rect? and just use Rect.zero if the rect is null. |
||
---|---|---|
.. | ||
android | ||
integration_test | ||
ios | ||
lib | ||
test_driver | ||
web | ||
.gitignore | ||
pubspec.yaml | ||
README.md |
integration_test_example
Demonstrates how to use the package:integration_test
.
To run integration_test/example_test.dart
,
Android / iOS
flutter drive \
--driver=test_driver/integration_test.dart \
--target=integration_test/example_test.dart
Web
In one shell, run Chromedriver (download here):
chromedriver --port 8444
Then, in another shell, run flutter drive
:
flutter drive \
--driver=test_driver/integration_test.dart \
--target=integration_test/example_test.dart \
-d web-server