Tests for Engine ensuring debug-mode apps are attached on iOS. (#37043)
This PR contains the tests for flutter/engine#10186.
This commit is contained in:
17
dev/integration_tests/ui/lib/empty.dart
Normal file
17
dev/integration_tests/ui/lib/empty.dart
Normal file
@@ -0,0 +1,17 @@
|
||||
// Copyright 2019 The Chromium 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/material.dart';
|
||||
import 'package:flutter_driver/driver_extension.dart';
|
||||
|
||||
/// This application does nothing but show a empty screen.
|
||||
void main() {
|
||||
enableFlutterDriverExtension();
|
||||
runApp(Empty());
|
||||
}
|
||||
|
||||
class Empty extends StatelessWidget {
|
||||
@override
|
||||
Widget build(BuildContext context) => Container();
|
||||
}
|
||||
8
dev/integration_tests/ui/lib/exit.dart
Normal file
8
dev/integration_tests/ui/lib/exit.dart
Normal file
@@ -0,0 +1,8 @@
|
||||
// Copyright 2019 The Chromium 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 'dart:io';
|
||||
|
||||
/// This application exits immediately.
|
||||
void main() => exit(0);
|
||||
23
dev/integration_tests/ui/test_driver/empty_test.dart
Normal file
23
dev/integration_tests/ui/test_driver/empty_test.dart
Normal file
@@ -0,0 +1,23 @@
|
||||
// Copyright 2019 The Chromium 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_driver/flutter_driver.dart';
|
||||
import 'package:test/test.dart' hide TypeMatcher, isInstanceOf;
|
||||
|
||||
// Connect and disconnect from the empty app.
|
||||
void main() {
|
||||
group('FlutterDriver', () {
|
||||
FlutterDriver driver;
|
||||
|
||||
setUpAll(() async {
|
||||
driver = await FlutterDriver.connect();
|
||||
});
|
||||
|
||||
tearDownAll(() async {
|
||||
await driver.close();
|
||||
});
|
||||
|
||||
test('empty', () async {}, timeout: const Timeout(Duration(minutes: 1)));
|
||||
});
|
||||
}
|
||||
Reference in New Issue
Block a user