[flutter_tools] Support Integration Tests (#76200)
This commit is contained in:
@@ -0,0 +1,41 @@
|
||||
<<skip until matching line>>
|
||||
══╡ EXCEPTION CAUGHT BY FLUTTER TEST FRAMEWORK ╞════════════════════════════════════════════════════
|
||||
The following message was thrown running a test:
|
||||
Who lives, who dies, who tells your story\?
|
||||
|
||||
When the exception was thrown, this was the stack:
|
||||
#0 main.<anonymous closure> \(.+[/\\]dev[/\\]automated_tests[/\\]integration_test[/\\]exception_handling_test\.dart:10:5\)
|
||||
<<skip until matching line>>
|
||||
The test description was:
|
||||
Exception handling in test harness - string
|
||||
<<skip until matching line>>
|
||||
Test failed\. See exception logs above\.
|
||||
The test description was: Exception handling in test harness - string
|
||||
<<skip until matching line>>
|
||||
══╡ EXCEPTION CAUGHT BY FLUTTER TEST FRAMEWORK ╞════════════════════════════════════════════════════
|
||||
The following assertion was thrown running a test:
|
||||
Who lives, who dies, who tells your story\?
|
||||
|
||||
When the exception was thrown, this was the stack:
|
||||
#0 main.<anonymous closure> \(.+[/\\]dev[/\\]automated_tests[/\\]integration_test[/\\]exception_handling_test\.dart:13:5\)
|
||||
<<skip until matching line>>
|
||||
The test description was:
|
||||
Exception handling in test harness - FlutterError
|
||||
<<skip until matching line>>
|
||||
Test failed\. See exception logs above\.
|
||||
The test description was: Exception handling in test harness - FlutterError
|
||||
<<skip until matching line>>
|
||||
══╡ EXCEPTION CAUGHT BY FLUTTER TEST FRAMEWORK ╞════════════════════════════════════════════════════
|
||||
The following message was thrown running a test:
|
||||
Who lives, who dies, who tells your story\?
|
||||
|
||||
When the exception was thrown, this was the stack:
|
||||
.*(TODO\(jiahaog\): Remove --no-chain-stack-traces and replace this with the actual stack once https://github.com/dart-lang/stack_trace/issues/106 is fixed)?
|
||||
<<skip until matching line>>
|
||||
The test description was:
|
||||
Exception handling in test harness - uncaught Future error
|
||||
<<skip until matching line>>
|
||||
Test failed\. See exception logs above\.
|
||||
The test description was: Exception handling in test harness - uncaught Future error
|
||||
<<skip until matching line>>
|
||||
.*..:.. \+0 -3: Some tests failed\. *
|
||||
@@ -0,0 +1,18 @@
|
||||
// Copyright 2014 The Flutter Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
import 'package:flutter/foundation.dart';
|
||||
import 'package:flutter_test/flutter_test.dart';
|
||||
|
||||
void main() {
|
||||
testWidgets('Exception handling in test harness - string', (WidgetTester tester) async {
|
||||
throw 'Who lives, who dies, who tells your story?';
|
||||
});
|
||||
testWidgets('Exception handling in test harness - FlutterError', (WidgetTester tester) async {
|
||||
throw FlutterError('Who lives, who dies, who tells your story?');
|
||||
});
|
||||
testWidgets('Exception handling in test harness - uncaught Future error', (WidgetTester tester) async {
|
||||
Future<void>.error('Who lives, who dies, who tells your story?');
|
||||
});
|
||||
}
|
||||
@@ -0,0 +1,2 @@
|
||||
<<skip until matching line>>
|
||||
[0-9]+:[0-9]+ [+]1: All tests passed!
|
||||
@@ -0,0 +1,9 @@
|
||||
// Copyright 2014 The Flutter Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
import 'package:flutter_test/flutter_test.dart';
|
||||
|
||||
void main() {
|
||||
testWidgets('A trivial widget test', (WidgetTester tester) async {});
|
||||
}
|
||||
@@ -8,6 +8,8 @@ dependencies:
|
||||
sdk: flutter
|
||||
flutter_test:
|
||||
sdk: flutter
|
||||
integration_test:
|
||||
sdk: flutter
|
||||
test: 1.16.5
|
||||
|
||||
_fe_analyzer_shared: 19.0.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade"
|
||||
|
||||
Reference in New Issue
Block a user