- 13 Jun, 2018 1 commit
-
-
Chris Bracken authored
fuchsia_tester.dart still assumes Dart 1. Previously, it ran tests directly from source, flutter_platform.dart automatically runs a kernel compile when operating in Dart 2 mode, but this assumes a functional Dart SDK is available in the artifacts directly, and fuchsia_tester.dart mocks out the artifacts directory with an empty temp dir. Remaining work is: 1. Get the frontend server building as a dependency on Fuchsia. 2. Patch fuchsia_tester.dart to use a valid Dart SDK and frontend server. This also reverts migration to Dart 2 typedef syntax. This reverts commit 6c56bb24. (#18362) This reverts commit 3daebd05. (#18316)
-
- 11 Jun, 2018 1 commit
-
-
Greg Spencer authored
Now that Dart 1 is turned off, reapplying my change to turn on the prefer_generic_function_type_aliases analysis option, and fix all the typedefs to Dart 2 preferred syntax. Also eliminated the unused analysis_options_repo.yaml file and turned on public_member_api_docs in analysys_options.yaml. No logic changes, just changing the typedef syntax for all typedefs, and updating analysis options.
-
- 05 Jun, 2018 1 commit
-
-
Alexandre Ardhuin authored
-
- 30 May, 2018 2 commits
-
-
Greg Spencer authored
Revert "Update typedef syntax to use Function notation and turn on lint for old notation. (#18035)" (#18041) This reverts commit 32586020.
-
Greg Spencer authored
Fixes #18028 Just changes typedef declarations, no logic changes.
-
- 16 Jan, 2018 1 commit
-
-
Ian Hickson authored
Seems like we don't yet run the flutter tests on Windows, but we're close to being able to. This makes some minor changes to make that more possible: - fix the stack parsing code to support Windows paths - fix the tests for the stack error handling code to handle Windows paths - skip some tests that rely on Ahem font metrics
-
- 14 Dec, 2017 1 commit
-
-
Ian Hickson authored
Fixes https://github.com/flutter/flutter/issues/10695
-
- 10 Oct, 2017 3 commits
-
-
Alexander Aprelev authored
-
Alexander Aprelev authored
This reverts commit e7061698. This causes preview-dart-2 test failures.
-
Alexander Aprelev authored
* Roll engine * Move assert requiring 'this' from initializer to constructor body * Update test expected message * Relax regexp to allow wider array of dart uris
-
- 07 Oct, 2017 1 commit
-
-
Ian Hickson authored
Also: * Provide a better message when you lerp from infinity to finity constraints. * Make the striped marker support RTL. * By popular demand, dump a warning to the console the first time a particular Flex overflows. (Resets on hot reload.)
-
- 21 Sep, 2017 1 commit
-
-
Alexandre Ardhuin authored
-
- 10 May, 2017 1 commit
-
-
Chris Bracken authored
Also includes minor doc fixes.
-
- 09 May, 2017 1 commit
-
-
Chris Bracken authored
-
- 03 May, 2017 1 commit
-
-
Ian Hickson authored
-
- 22 Apr, 2017 1 commit
-
-
Alexandre Ardhuin authored
* enable lint overridden_fields * address review comment
-
- 08 Mar, 2017 1 commit
-
-
Ian Hickson authored
-
- 04 Mar, 2017 1 commit
-
-
Chris Bracken authored
Covers lib/ in package:flutter.
-
- 23 Jan, 2017 1 commit
-
-
Ian Hickson authored
See https://github.com/dart-lang/sdk/issues/28463, which I think is a regression. This also fixes the regression introduced by https://codereview.chromium.org/2559773002 whereby we were no longer checking any of the lints.
-
- 17 Jan, 2017 1 commit
-
-
Adam Barth authored
* MultiTapGestureRecognizer previously would assert if there was no competition. * GestureArenaTeam would always select the first recongizer as the winner even if a later recognizer actually accepted the pointer sequence. * debugPrintStack would fail a type check if maxFrames was non-null. * FractionalOffset.lerp would throw a null-pointer exception if its second argument was null. Also, add a number of tests for previously untested lines of code.
-
- 08 Sep, 2016 1 commit
-
-
Ian Hickson authored
Previously, pumpWidget() would do a partial pump (it didn't trigger Ticker callbacks or post-frame callbacks), and pump() would do a full pump. This patch brings them closer together. It also makes runApp run a full actual frame, rather than skipping the transient callback part of the frame logic. Having "half-frames" in the system was confusing and could lead to bugs where code expecting to run before the next layout pass didn't because a "half-frame" ran first. Also, make Tickers start ticking in the frame that they were started in, if they were started during a frame. This means we no longer spin a frame for t=0, we jump straight to the first actual frame. Other changes in this patch: * rename WidgetsBinding._runApp to WidgetsBinding.attachRootWidget, so that tests can use it to more accurately mock out runApp. * allow loadStructuredData to return synchronously. * make handleBeginFrame handle not being given a time stamp. * make DataPipeImageProvider.loadAsync protected (rather than private), and document it. There wasn't really a reason for it to be private. * fix ImageConfiguration.toString. * introduce debugPrintBuildScope and debugPrintScheduleBuildForStacks, which can help debug problems with widgets getting marked as dirty but not cleaned. * make debugPrintRebuildDirtyWidgets say "Building" the first time and "Rebuilding" the second, to make it clearer when a widget is first created. This makes debugging widget lifecycle issues much easier. * make debugDumpApp more resilient. * debugPrintStack now takes a label that is printed before the stack. * improve the banner shown for debugPrintBeginFrameBanner. * various and sundry documentation fixes
-
- 11 Aug, 2016 1 commit
-
-
Ian Hickson authored
Changes in this patch: - iOS now uses a different scrollDrag constant than Android. - ScrollConfigurationDelegate now knows about target platforms. - ScrollBehaviors now know about target platforms. - RawInputLine now has to be told what platform it's targetting. - PageableList now has a concept of target platform. - make debugPrintStack filter its stack. - move debugPrintStack to `assertions.dart`. - add support for limiting the number of frames to debugPrintStack. - make defaultTargetPlatform default to android in test environments. - remove OverscrollStyle and MaterialApp's overscrollStyle argument. You can now control the overscroll style using Theme.platform. - the default scroll configuration is now private to avoid people relying on the defaultTargetPlatform getter in their subclasses (since they really should use Theme.of(context).platform). - fix some typos I noticed in some tests. - added a test for flinging scrollables, that checks that the behavior differs on the two target platforms. - made flingFrom and fling in the test API pump the frames. - added more docs to the test API. - made the TestAsyncUtils.guard() method report uncaught errors to help debug errors when using that API.
-
- 03 Aug, 2016 1 commit
-
-
Ian Hickson authored
Adds Scheduler.debugPrintTransientCallbackRegistrationStack so that you can find out how your current callback got registered.
-
- 28 Jul, 2016 1 commit
-
-
Ian Hickson authored
- show the next error fully after a hot reload - hide _AssertionError in stacks - immediately rebuild after a reassemble, so that hit tests work - catch errors when notifying global key listeners
-
- 25 May, 2016 1 commit
-
-
Adam Barth authored
For consistency. Fixes #4142
-
- 20 May, 2016 1 commit
-
-
Ian Hickson authored
-
- 18 May, 2016 1 commit
-
-
Ian Hickson authored
Don't suggest filing an issue when we can definitively say that the assertion in question was not thrown from within the flutter package. Fixes https://github.com/flutter/flutter/issues/3812. Put the stack trace first after the message, with more details below the stack trace, since the stack is often very useful and the stacks are no longer stupidly long. Better document the 'rescheduling' feature, and improve the error handling asserts when it is misused. Fixes https://github.com/flutter/flutter/issues/3888. Improve the wording around the stack dump for exceptions during callbacks. Improve the color and font size of messages in live tests. Fixes https://github.com/flutter/flutter/issues/4018.
-
- 16 May, 2016 1 commit
-
-
Ian Hickson authored
This makes it possible to substitute 'flutter run' for 'flutter test' and actually watch a test run on a device. For any test that depends on flutter_test: 1. Remove any import of 'package:test/test.dart'. 2. Replace `testWidgets('...', (WidgetTester tester) {` with `testWidgets('...', (WidgetTester tester) async {` 3. Add an "await" in front of calls to any of the following: * tap() * tapAt() * fling() * flingFrom() * scroll() * scrollAt() * pump() * pumpWidget() 4. Replace any calls to `tester.flushMicrotasks()` with calls to `await tester.idle()`. There's a guarding API that you can use, if you have particularly complicated tests, to get better error messages. Search for TestAsyncUtils.
-
- 29 Apr, 2016 1 commit
-
-
Ian Hickson authored
* Refactor widget test framework Instead of: ```dart test("Card Collection smoke test", () { testWidgets((WidgetTester tester) { ``` ...you now say: ```dart testWidgets("Card Collection smoke test", (WidgetTester tester) { ``` Instead of: ```dart expect(tester, hasWidget(find.text('hello'))); ``` ...you now say: ```dart expect(find.text('hello'), findsOneWidget); ``` Instead of the previous API (exists, widgets, widget, stateOf, elementOf, etc), you now have the following comprehensive API. All these are functions that take a Finder, except the all* properties. * `any()` - true if anything matches, c.f. `Iterable.any` * `allWidgets` - all the widgets in the tree * `widget()` - the one and only widget that matches the finder * `firstWidget()` - the first widget that matches the finder * `allElements` - all the elements in the tree * `element()` - the one and only element that matches the finder * `firstElement()` - the first element that matches the finder * `allStates` - all the `State`s in the tree * `state()` - the one and only state that matches the finder * `firstState()` - the first state that matches the finder * `allRenderObjects` - all the render objects in the tree * `renderObject()` - the one and only render object that matches the finder * `firstRenderObject()` - the first render object that matches the finder There's also `layers' which returns the list of current layers. `tap`, `fling`, getCenter, getSize, etc, take Finders, like the APIs above, and expect there to only be one matching widget. The finders are: * `find.text(String text)` * `find.widgetWithText(Type widgetType, String text)` * `find.byKey(Key key)` * `find.byType(Type type)` * `find.byElementType(Type type)` * `find.byConfig(Widget config)` * `find.byWidgetPredicate(WidgetPredicate predicate)` * `find.byElementPredicate(ElementPredicate predicate)` The matchers (for `expect`) are: * `findsNothing` * `findsWidgets` * `findsOneWidget` * `findsNWidgets(n)` * `isOnStage` * `isOffStage` * `isInCard` * `isNotInCard` Benchmarks now use benchmarkWidgets instead of testWidgets. Also, for those of you using mockers, `serviceMocker` now automatically handles the binding initialization. This patch also: * changes how tests are run so that we can more easily swap the logic out for a "real" mode instead of FakeAsync. * introduces CachingIterable. * changes how flutter_driver interacts with the widget tree to use the aforementioned new API rather than ElementTreeTester, which is gone. * removes ElementTreeTester. * changes the semantics of a test for scrollables because we couldn't convince ourselves that the old semantics made sense; it only worked before because flushing the microtasks after every event was broken. * fixes the flushing of microtasks after every event. * Reindent the tests * Fix review comments
-
- 15 Apr, 2016 2 commits
-
-
Ian Hickson authored
Fixes https://github.com/flutter/flutter/issues/3352
-
Ian Hickson authored
We're getting back to the point where we have a bunch of foundation APIs and it's getting confusing having them mixed with services/.
-
- 12 Apr, 2016 1 commit
-
-
Ian Hickson authored
This also shrinks the width of the error messages a bit because now that we use 'package:' URLs the stacks are a bit narrower.
-
- 03 Apr, 2016 1 commit
-
-
Ian Hickson authored
-
- 02 Apr, 2016 1 commit
-
-
Ian Hickson authored
- Create a FlutterErrorDetails struct-like class that describes an exception along with more details that aren't in the exception, like where it was caught and what was going on when it was caught. - Provide a FlutterError static API for handling these objects: - FlutterError.onError which is called whenever Flutter catches an error. - FlutterError.reportError() which handles an error. - FlutterError.dumpErrorToConsole() which is the default behavior for onError. - Removes all the existing exception handler callbacks. - Replaces all the existing places that described exceptions using debugPrint with calls to FlutterError.reportError(). - Extend lockState() to also catch exceptions, so that we catch exceptions that happen during finalizers. - Make the test framework catch errors and treat them as failures. - Provide a mechanism to override this behavior in the test framework. - Make the tests that used to depend on the exception handler callbacks use this new mechanism. - Make pump() also support the phase argument. - Improve some tests using these new features. Fixes #2356, #2988, #2985, #2220.
-
- 18 Mar, 2016 1 commit
-
-
Hixie authored
-
- 14 Mar, 2016 1 commit
-
-
Hixie authored
-
- 11 Mar, 2016 1 commit
-
-
Ian Hickson authored
Specifically: * Handle null styles in TextSpan without crashing in toString(). * Handle null children in TextSpan child lists without crashing in toString(). * Handle entirely empty TextSpans in toString() explicitly. * Assert that TextSpans don't contain nulls in various places. This is done more often than one might think necessary, because it turns out that TextSpan takes a (mutable) List for one of its arguments, so who knows what it will contain at any given time. By asserting all over the place, hopefully we'll catch it near the change if they do change it. * Add a RichText example to Stocks to exercise RichText and TextSpans. See also: https://github.com/flutter/flutter/issues/2514, https://github.com/flutter/flutter/issues/2519
-
- 22 Jan, 2016 1 commit
-
-
Devon Carew authored
remove device type specific checks
-