fix some formatting issues (#28809)
* fix some formatting issues
* address review comments
* fix indent
diff --git a/packages/flutter_tools/lib/src/application_package.dart b/packages/flutter_tools/lib/src/application_package.dart
index 82816b7..61a13bf 100644
--- a/packages/flutter_tools/lib/src/application_package.dart
+++ b/packages/flutter_tools/lib/src/application_package.dart
@@ -98,7 +98,7 @@
return null;
}
- final List<String> aaptArgs = <String>[
+ final List<String> aaptArgs = <String>[
aaptPath,
'dump',
'xmltree',
diff --git a/packages/flutter_tools/lib/src/build_runner/build_script_generator.dart b/packages/flutter_tools/lib/src/build_runner/build_script_generator.dart
index 137ef53..bde12be 100644
--- a/packages/flutter_tools/lib/src/build_runner/build_script_generator.dart
+++ b/packages/flutter_tools/lib/src/build_runner/build_script_generator.dart
@@ -279,4 +279,4 @@
/// Whether [child] specifies that it wants to run before [parent].
bool _mustRunBefore(BuilderDefinition parent, BuilderDefinition child) => child.runsBefore.contains(parent.key);
-}
\ No newline at end of file
+}
diff --git a/packages/flutter_tools/lib/src/commands/generate.dart b/packages/flutter_tools/lib/src/commands/generate.dart
index 71b0a8a..2b0ed3c 100644
--- a/packages/flutter_tools/lib/src/commands/generate.dart
+++ b/packages/flutter_tools/lib/src/commands/generate.dart
@@ -27,4 +27,4 @@
await codeGenerator.generate(mainPath: argResults['target']);
return null;
}
-}
\ No newline at end of file
+}
diff --git a/packages/flutter_tools/lib/src/convert.dart b/packages/flutter_tools/lib/src/convert.dart
index 2aedb81..9d8b9c1 100644
--- a/packages/flutter_tools/lib/src/convert.dart
+++ b/packages/flutter_tools/lib/src/convert.dart
@@ -46,4 +46,4 @@
}
return result;
}
-}
\ No newline at end of file
+}
diff --git a/packages/flutter_tools/lib/src/devfs.dart b/packages/flutter_tools/lib/src/devfs.dart
index 05e9292..e6dabb1 100644
--- a/packages/flutter_tools/lib/src/devfs.dart
+++ b/packages/flutter_tools/lib/src/devfs.dart
@@ -386,20 +386,16 @@
this.rootDirectory, {
String packagesFilePath,
}) : _operations = ServiceProtocolDevFSOperations(serviceProtocol),
- _httpWriter = _DevFSHttpWriter(fsName, serviceProtocol) {
- _packagesFilePath =
- packagesFilePath ?? fs.path.join(rootDirectory.path, kPackagesFileName);
- }
+ _httpWriter = _DevFSHttpWriter(fsName, serviceProtocol),
+ _packagesFilePath = packagesFilePath ?? fs.path.join(rootDirectory.path, kPackagesFileName);
DevFS.operations(
this._operations,
this.fsName,
this.rootDirectory, {
String packagesFilePath,
- }) : _httpWriter = null {
- _packagesFilePath =
- packagesFilePath ?? fs.path.join(rootDirectory.path, kPackagesFileName);
- }
+ }) : _httpWriter = null,
+ _packagesFilePath = packagesFilePath ?? fs.path.join(rootDirectory.path, kPackagesFileName);
final DevFSOperations _operations;
final _DevFSHttpWriter _httpWriter;
diff --git a/packages/flutter_tools/lib/src/flutter_manifest.dart b/packages/flutter_tools/lib/src/flutter_manifest.dart
index 6ad2e69..0c094f7 100644
--- a/packages/flutter_tools/lib/src/flutter_manifest.dart
+++ b/packages/flutter_tools/lib/src/flutter_manifest.dart
@@ -435,4 +435,4 @@
}
}
}
-}
\ No newline at end of file
+}
diff --git a/packages/flutter_tools/lib/src/fuchsia/fuchsia_device.dart b/packages/flutter_tools/lib/src/fuchsia/fuchsia_device.dart
index ffbe9dd..9a13ea6 100644
--- a/packages/flutter_tools/lib/src/fuchsia/fuchsia_device.dart
+++ b/packages/flutter_tools/lib/src/fuchsia/fuchsia_device.dart
@@ -39,7 +39,8 @@
FuchsiaDevice _device;
ApplicationPackage _app;
- @override String get name => _device.name;
+ @override
+ String get name => _device.name;
Stream<String> _logLines;
@override
diff --git a/packages/flutter_tools/lib/src/macos/application_package.dart b/packages/flutter_tools/lib/src/macos/application_package.dart
index 71c26aa..31fd59e 100644
--- a/packages/flutter_tools/lib/src/macos/application_package.dart
+++ b/packages/flutter_tools/lib/src/macos/application_package.dart
@@ -16,13 +16,13 @@
abstract class MacOSApp extends ApplicationPackage {
MacOSApp({@required String projectBundleId}) : super(id: projectBundleId);
- /// Creates a new [MacOSApp] from an existing app bundle.
- ///
- /// `applicationBinary` is the path to the framework directory created by an
- /// Xcode build. By default, this is located under
- /// "~/Library/Developer/Xcode/DerivedData/" and contains an executable
- /// which is expected to start the application and send the observatory
- /// port over stdout.
+ /// Creates a new [MacOSApp] from an existing app bundle.
+ ///
+ /// `applicationBinary` is the path to the framework directory created by an
+ /// Xcode build. By default, this is located under
+ /// "~/Library/Developer/Xcode/DerivedData/" and contains an executable
+ /// which is expected to start the application and send the observatory
+ /// port over stdout.
factory MacOSApp.fromPrebuiltApp(FileSystemEntity applicationBinary) {
final FileSystemEntityType entityType = fs.typeSync(applicationBinary.path);
if (entityType == FileSystemEntityType.notFound) {
@@ -71,7 +71,7 @@
String get executable;
}
- class PrebuiltMacOSApp extends MacOSApp {
+class PrebuiltMacOSApp extends MacOSApp {
PrebuiltMacOSApp({
@required this.bundleDir,
@required this.bundleName,
diff --git a/packages/flutter_tools/lib/src/project.dart b/packages/flutter_tools/lib/src/project.dart
index 91a0ef8..f14e2a6 100644
--- a/packages/flutter_tools/lib/src/project.dart
+++ b/packages/flutter_tools/lib/src/project.dart
@@ -467,7 +467,7 @@
final FlutterProject parent;
- Future<void> ensureReadyForPlatformSpecificTooling() async {
+ Future<void> ensureReadyForPlatformSpecificTooling() async {
/// Generate index.html in build/web. Eventually we could support
/// a custom html under the web sub directory.
final Directory outputDir = fs.directory(getWebBuildDirectory());
diff --git a/packages/flutter_tools/test/build_runner/build_runner_test.dart b/packages/flutter_tools/test/build_runner/build_runner_test.dart
index fb7575a..0d3e56a 100644
--- a/packages/flutter_tools/test/build_runner/build_runner_test.dart
+++ b/packages/flutter_tools/test/build_runner/build_runner_test.dart
@@ -33,4 +33,4 @@
});
}
-class MockPlatform extends Mock implements Platform {}
\ No newline at end of file
+class MockPlatform extends Mock implements Platform {}
diff --git a/packages/flutter_tools/test/cache_test.dart b/packages/flutter_tools/test/cache_test.dart
index 079b045..1e7916f 100644
--- a/packages/flutter_tools/test/cache_test.dart
+++ b/packages/flutter_tools/test/cache_test.dart
@@ -162,4 +162,4 @@
class MockRandomAccessFile extends Mock implements RandomAccessFile {}
class MockCachedArtifact extends Mock implements CachedArtifact {}
class MockInternetAddress extends Mock implements InternetAddress {}
-class MockCache extends Mock implements Cache {}
\ No newline at end of file
+class MockCache extends Mock implements Cache {}
diff --git a/packages/flutter_tools/test/commands/doctor_test.dart b/packages/flutter_tools/test/commands/doctor_test.dart
index dfa032e..5329d47 100644
--- a/packages/flutter_tools/test/commands/doctor_test.dart
+++ b/packages/flutter_tools/test/commands/doctor_test.dart
@@ -212,7 +212,7 @@
});
- group('doctor with fake validators', () {
+ group('doctor with fake validators', () {
testUsingContext('validate non-verbose output format for run without issues', () async {
expect(await FakeQuietDoctor().diagnose(verbose: false), isTrue);
expect(testLogger.statusText, equals(
diff --git a/packages/flutter_tools/test/integration/expression_evaluation_test.dart b/packages/flutter_tools/test/integration/expression_evaluation_test.dart
index 498c7f8..7ab5356 100644
--- a/packages/flutter_tools/test/integration/expression_evaluation_test.dart
+++ b/packages/flutter_tools/test/integration/expression_evaluation_test.dart
@@ -144,17 +144,16 @@
Future<void> evaluateComplexExpressions(FlutterTestDriver flutter) async {
final InstanceRef res = await flutter.evaluateInFrame('new DateTime.now().year');
- expect(res.kind == InstanceKind.kInt && res.valueAsString == DateTime.now().year.toString(), isTrue);
+ expect(res.kind == InstanceKind.kInt && res.valueAsString == DateTime.now().year.toString(), isTrue);
}
Future<void> evaluateComplexReturningExpressions(FlutterTestDriver flutter) async {
final DateTime now = DateTime.now();
- final InstanceRef resp = await flutter.evaluateInFrame('new DateTime.now()');
- expect(resp.classRef.name, equals('DateTime'));
- // Ensure we got a reasonable approximation. The more accurate we try to
- // make this, the more likely it'll fail due to differences in the time
- // in the remote VM and the local VM at the time the code runs.
- final InstanceRef res = await flutter.evaluate(resp.id, r'"$year-$month-$day"');
- expect(res.valueAsString,
- equals('${now.year}-${now.month}-${now.day}'));
+ final InstanceRef resp = await flutter.evaluateInFrame('new DateTime.now()');
+ expect(resp.classRef.name, equals('DateTime'));
+ // Ensure we got a reasonable approximation. The more accurate we try to
+ // make this, the more likely it'll fail due to differences in the time
+ // in the remote VM and the local VM at the time the code runs.
+ final InstanceRef res = await flutter.evaluate(resp.id, r'"$year-$month-$day"');
+ expect(res.valueAsString, equals('${now.year}-${now.month}-${now.day}'));
}
diff --git a/packages/flutter_tools/test/web/compile_test.dart b/packages/flutter_tools/test/web/compile_test.dart
index 0316a33..2b7255b 100644
--- a/packages/flutter_tools/test/web/compile_test.dart
+++ b/packages/flutter_tools/test/web/compile_test.dart
@@ -51,4 +51,4 @@
}
class MockProcessManager extends Mock implements ProcessManager {}
-class MockProcess extends Mock implements Process {}
\ No newline at end of file
+class MockProcess extends Mock implements Process {}