Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
F
Front-End
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abdullh.alsoleman
Front-End
Commits
8e05e59c
Unverified
Commit
8e05e59c
authored
Dec 03, 2020
by
Kate Lovett
Committed by
GitHub
Dec 03, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Revert "Add integration_test template to create template (#70240)" (#71660)
This reverts commit
d047d108
.
parent
81e1f7d1
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
0 additions
and
126 deletions
+0
-126
app_test.dart.tmpl
...r_tools/templates/app/integration_test/app_test.dart.tmpl
+0
-48
driver.dart.tmpl
...ter_tools/templates/app/integration_test/driver.dart.tmpl
+0
-8
pubspec.yaml.tmpl
packages/flutter_tools/templates/app/pubspec.yaml.tmpl
+0
-2
template_manifest.json
packages/flutter_tools/templates/template_manifest.json
+0
-2
create_test.dart
...tter_tools/test/commands.shard/permeable/create_test.dart
+0
-4
integration_test_test.dart
...r_tools/test/integration.shard/integration_test_test.dart
+0
-62
No files found.
packages/flutter_tools/templates/app/integration_test/app_test.dart.tmpl
deleted
100644 → 0
View file @
81e1f7d1
// This is a basic Flutter integration test.
//
// To perform an interaction with a widget in your test, use the WidgetTester
// utility that Flutter provides. For example, you can send tap and scroll
// gestures. You can also use WidgetTester to find child widgets in the widget
// tree, read text, and verify that the values of widget properties are correct.
import 'package:flutter/material.dart';
import 'package:flutter_test/flutter_test.dart';
import 'package:integration_test/integration_test.dart';
import 'package:{{projectName}}/main.dart' as app;
void main() => run(_testMain);
void _testMain() {
testWidgets('Counter increments smoke test', (WidgetTester tester) async {
// Build our app and trigger a frame.
app.main();
// Trigger a frame.
await tester.pumpAndSettle();
{{^withPluginHook}}
// Verify that our counter starts at 0.
expect(find.text('0'), findsOneWidget);
expect(find.text('1'), findsNothing);
// Tap the '+' icon and trigger a frame.
await tester.tap(find.byIcon(Icons.add));
await tester.pump();
// Verify that our counter has incremented.
expect(find.text('0'), findsNothing);
expect(find.text('1'), findsOneWidget);
{{/withPluginHook}}
{{#withPluginHook}}
// Verify that platform version is retrieved.
expect(
find.byWidgetPredicate(
(Widget widget) => widget is Text &&
widget.data.startsWith('Running on:'),
),
findsOneWidget,
);
{{/withPluginHook}}
});
}
packages/flutter_tools/templates/app/integration_test/driver.dart.tmpl
deleted
100644 → 0
View file @
81e1f7d1
// This file is provided as a convenience for running integration tests via the
// flutter drive command.
//
// flutter drive --driver integration_test/driver.dart --target integration_test/app_test.dart
import 'package:integration_test/integration_test_driver.dart';
Future<void> main() => integrationDriver();
packages/flutter_tools/templates/app/pubspec.yaml.tmpl
View file @
8e05e59c
...
...
@@ -43,8 +43,6 @@ dependencies:
dev_dependencies:
flutter_test:
sdk: flutter
integration_test:
sdk: flutter
# For information on the generic Dart part of this file, see the
# following page: https://dart.dev/tools/pub/pubspec
...
...
packages/flutter_tools/templates/template_manifest.json
View file @
8e05e59c
...
...
@@ -33,8 +33,6 @@
"templates/app/android.tmpl/gradle/wrapper/gradle-wrapper.properties"
,
"templates/app/android.tmpl/gradle.properties.tmpl"
,
"templates/app/android.tmpl/settings.gradle"
,
"templates/app/integration_test/app_test.dart.tmpl"
,
"templates/app/integration_test/driver.dart.tmpl"
,
"templates/app/ios-objc.tmpl/Runner/AppDelegate.h"
,
"templates/app/ios-objc.tmpl/Runner/AppDelegate.m"
,
"templates/app/ios-objc.tmpl/Runner/main.m"
,
...
...
packages/flutter_tools/test/commands.shard/permeable/create_test.dart
View file @
8e05e59c
...
...
@@ -299,8 +299,6 @@ void main() {
'ios/Runner/main.m'
,
'lib/main.dart'
,
'test/widget_test.dart'
,
'integration_test/app_test.dart'
,
'integration_test/driver.dart'
,
],
);
},
overrides:
<
Type
,
Generator
>{
...
...
@@ -366,8 +364,6 @@ void main() {
'ios/Runner/main.m'
,
'lib/main.dart'
,
'test/widget_test.dart'
,
'integration_test/app_test.dart'
,
'integration_test/driver.dart'
,
],
);
return
_runFlutterTest
(
projectDir
);
...
...
packages/flutter_tools/test/integration.shard/integration_test_test.dart
deleted
100644 → 0
View file @
81e1f7d1
// 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_tools/src/base/file_system.dart'
;
import
'package:flutter_tools/src/base/io.dart'
;
import
'../src/common.dart'
;
import
'test_utils.dart'
;
final
String
flutterBin
=
fileSystem
.
path
.
join
(
getFlutterRoot
(),
'bin'
,
platform
.
isWindows
?
'flutter.bat'
:
'flutter'
);
void
main
(
)
{
Directory
tempDir
;
setUpAll
(()
{
tempDir
=
createResolvedTempDirectorySync
(
'int_test.'
);
});
tearDownAll
(()
{
tryToDelete
(
tempDir
);
});
testWithoutContext
(
'flutter project default integration_test smoke test'
,
()
async
{
const
String
projectName
=
'integration_test_sample'
;
ProcessResult
result
=
await
processManager
.
run
(
<
String
>[
flutterBin
,
'create'
,
projectName
,
],
workingDirectory:
tempDir
.
path
,
);
expect
(
result
.
exitCode
,
0
);
final
Directory
projectDir
=
tempDir
.
childDirectory
(
projectName
);
expect
(
projectDir
.
existsSync
(),
true
);
final
Directory
integrationTestDir
=
projectDir
.
childDirectory
(
'integration_test'
);
expect
(
integrationTestDir
.
existsSync
(),
true
);
expect
(
integrationTestDir
.
childFile
(
'driver.dart'
).
existsSync
(),
true
);
expect
(
integrationTestDir
.
childFile
(
'app_test.dart'
).
existsSync
(),
true
);
result
=
await
processManager
.
run
(
<
String
>[
flutterBin
,
'drive'
,
'-d'
,
'flutter-tester'
,
'--driver'
,
'integration_test/driver.dart'
,
'-t'
,
'integration_test/app_test.dart'
,
],
workingDirectory:
projectDir
.
path
,
);
if
(
result
.
exitCode
!=
0
)
{
print
(
'================================= STDOUT ======================================='
);
print
(
result
.
stdout
);
print
(
'================================= STDERR ======================================='
);
print
(
result
.
stderr
);
fail
(
'flutter drive failed, see output.'
);
}
});
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment