enable lint prefer_equal_for_default_values (#18156)

This commit is contained in:
Alexandre Ardhuin
2018-06-05 08:50:40 +02:00
committed by GitHub
parent 6be81ebf9b
commit 09276bea25
390 changed files with 1920 additions and 1920 deletions

View File

@@ -144,7 +144,7 @@ class _TaskRunner {
/// A result of running a single task.
class TaskResult {
/// Constructs a successful result.
TaskResult.success(this.data, {this.benchmarkScoreKeys: const <String>[]})
TaskResult.success(this.data, {this.benchmarkScoreKeys = const <String>[]})
: this.succeeded = true,
this.message = 'success' {
const JsonEncoder prettyJson = const JsonEncoder.withIndent(' ');

View File

@@ -22,7 +22,7 @@ const Duration taskTimeoutWithGracePeriod = const Duration(minutes: 26);
///
/// Running the task in [silent] mode will suppress standard output from task
/// processes and only print standard errors.
Future<Map<String, dynamic>> runTask(String taskName, { bool silent: false }) async {
Future<Map<String, dynamic>> runTask(String taskName, { bool silent = false }) async {
final String taskExecutable = 'bin/tasks/$taskName.dart';
if (!file(taskExecutable).existsSync())

View File

@@ -231,7 +231,7 @@ Future<int> exec(
String executable,
List<String> arguments, {
Map<String, String> environment,
bool canFail: false,
bool canFail = false,
}) async {
final Process process = await startProcess(executable, arguments, environment: environment);
@@ -266,7 +266,7 @@ Future<String> eval(
String executable,
List<String> arguments, {
Map<String, String> environment,
bool canFail: false,
bool canFail = false,
}) async {
final Process process = await startProcess(executable, arguments, environment: environment);
@@ -297,8 +297,8 @@ Future<String> eval(
}
Future<int> flutter(String command, {
List<String> options: const <String>[],
bool canFail: false,
List<String> options = const <String>[],
bool canFail = false,
Map<String, String> environment,
}) {
final List<String> args = <String>[command]..addAll(options);
@@ -308,8 +308,8 @@ Future<int> flutter(String command, {
/// Runs a `flutter` command and returns the standard output as a string.
Future<String> evalFlutter(String command, {
List<String> options: const <String>[],
bool canFail: false,
List<String> options = const <String>[],
bool canFail = false,
Map<String, String> environment,
}) {
final List<String> args = <String>[command]..addAll(options);