Clean up ignores that are not ignoring anything (#78493)
This commit is contained in:
parent
65f232fd76
commit
a7e3b1a35d
@ -225,9 +225,6 @@ class VMServiceFlutterDriver extends FlutterDriver {
|
||||
|
||||
final Health health = await driver.checkHealth();
|
||||
if (health.status != HealthStatus.ok) {
|
||||
// TODO(dnfield): Remove ignore once internal repo is up to date
|
||||
// https://github.com/flutter/flutter/issues/74518
|
||||
// ignore: await_only_futures
|
||||
await client.dispose();
|
||||
await client.onDone;
|
||||
throw DriverError('Flutter application health check failed.');
|
||||
@ -519,9 +516,7 @@ class VMServiceFlutterDriver extends FlutterDriver {
|
||||
|
||||
@override
|
||||
Future<void> close() async {
|
||||
// TODO(dnfield): Remove ignore once internal repo is up to date
|
||||
// https://github.com/flutter/flutter/issues/74518
|
||||
await _serviceClient.dispose(); // ignore: await_only_futures
|
||||
await _serviceClient.dispose();
|
||||
await _serviceClient.onDone;
|
||||
}
|
||||
}
|
||||
|
@ -19,7 +19,6 @@ import 'dart:js_util' as js_util;
|
||||
/// * [_extension_io.dart], which has the dart:io implementation
|
||||
void registerWebServiceExtension(Future<Map<String, dynamic>> Function(Map<String, String>) call) {
|
||||
js_util.setProperty(html.window, r'$flutterDriver', allowInterop((dynamic message) async {
|
||||
// ignore: undefined_function, undefined_identifier
|
||||
final Map<String, String> params = Map<String, String>.from(
|
||||
jsonDecode(message as String) as Map<String, dynamic>);
|
||||
final Map<String, dynamic> result = Map<String, dynamic>.from(
|
||||
|
@ -2,7 +2,7 @@
|
||||
// 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'; // ignore: import_of_legacy_library_into_null_safe
|
||||
import 'package:flutter_driver/flutter_driver.dart';
|
||||
|
||||
class StubNestedCommand extends CommandWithTarget {
|
||||
StubNestedCommand(SerializableFinder finder, this.times, {Duration? timeout})
|
||||
|
@ -3,7 +3,7 @@
|
||||
// found in the LICENSE file.
|
||||
|
||||
import 'package:flutter_driver/driver_extension.dart';
|
||||
import 'package:flutter_driver/flutter_driver.dart'; // ignore: import_of_legacy_library_into_null_safe
|
||||
import 'package:flutter_driver/flutter_driver.dart';
|
||||
import 'package:flutter_test/flutter_test.dart';
|
||||
|
||||
import 'stub_command.dart';
|
||||
|
@ -2,7 +2,7 @@
|
||||
// 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'; // ignore: import_of_legacy_library_into_null_safe
|
||||
import 'package:flutter_driver/flutter_driver.dart';
|
||||
|
||||
class StubFinder extends SerializableFinder {
|
||||
StubFinder(this.keyString);
|
||||
|
@ -47,7 +47,6 @@ class _AsyncScope {
|
||||
class TestAsyncUtils {
|
||||
// This class is not meant to be instatiated or extended; this constructor
|
||||
// prevents instantiation and extension.
|
||||
// ignore: unused_element
|
||||
TestAsyncUtils._();
|
||||
static const String _className = 'TestAsyncUtils';
|
||||
|
||||
|
@ -10,7 +10,7 @@ import 'package:flutter_test/flutter_test.dart';
|
||||
|
||||
void main() {
|
||||
test('TestWindow can handle new methods without breaking', () {
|
||||
final dynamic testWindow = TestWindow(window: ui.window); // ignore: unnecessary_nullable_for_final_variable_declarations
|
||||
final dynamic testWindow = TestWindow(window: ui.window);
|
||||
expect(testWindow.someNewProperty, null);
|
||||
});
|
||||
|
||||
|
@ -427,9 +427,7 @@ class AppDomain extends Domain {
|
||||
registerHandler('detach', detach);
|
||||
}
|
||||
|
||||
// TODO(jonahwilliams): update after google3 uuid is updated.
|
||||
// ignore: prefer_const_constructors
|
||||
static final Uuid _uuidGenerator = Uuid();
|
||||
static const Uuid _uuidGenerator = Uuid();
|
||||
|
||||
static String _getNewAppId() => _uuidGenerator.v4();
|
||||
|
||||
|
@ -4,7 +4,6 @@
|
||||
|
||||
// @dart = 2.8
|
||||
|
||||
// ignore_for_file: implementation_imports
|
||||
|
||||
import 'dart:async';
|
||||
import 'dart:typed_data';
|
||||
|
@ -4,8 +4,6 @@
|
||||
|
||||
// @dart = 2.8
|
||||
|
||||
// ignore_for_file: implementation_imports
|
||||
|
||||
import 'dart:async';
|
||||
import 'dart:typed_data';
|
||||
|
||||
@ -19,7 +17,7 @@ import 'package:shelf/shelf_io.dart' as shelf_io;
|
||||
import 'package:shelf_static/shelf_static.dart';
|
||||
import 'package:shelf_web_socket/shelf_web_socket.dart';
|
||||
import 'package:stream_channel/stream_channel.dart';
|
||||
import 'package:test_core/src/platform.dart';
|
||||
import 'package:test_core/src/platform.dart'; // ignore: implementation_imports
|
||||
import 'package:web_socket_channel/web_socket_channel.dart';
|
||||
import 'package:webkit_inspection_protocol/webkit_inspection_protocol.dart' hide StackTrace;
|
||||
|
||||
|
@ -892,9 +892,6 @@ class FlutterVmService {
|
||||
}
|
||||
|
||||
Future<void> dispose() async {
|
||||
// TODO(dnfield): Remove ignore once internal repo is up to date
|
||||
// https://github.com/flutter/flutter/issues/74518
|
||||
// ignore: await_only_futures
|
||||
await service.dispose();
|
||||
}
|
||||
}
|
||||
|
@ -634,9 +634,6 @@ class FlutterRunTestDriver extends FlutterTestDriver {
|
||||
}
|
||||
if (_vmService != null) {
|
||||
_debugPrint('Closing VM service...');
|
||||
// TODO(dnfield): Remove ignore once internal repo is up to date
|
||||
// https://github.com/flutter/flutter/issues/74518
|
||||
// ignore: await_only_futures
|
||||
await _vmService.dispose();
|
||||
}
|
||||
if (_currentRunningAppId != null) {
|
||||
|
@ -43,8 +43,8 @@ class PluginEventChannel<T> {
|
||||
this.name, [
|
||||
this.codec = const StandardMethodCodec(),
|
||||
this.binaryMessenger,
|
||||
]) : assert(name != null), // ignore: unnecessary_null_comparison
|
||||
assert(codec != null); // ignore: unnecessary_null_comparison
|
||||
]) : assert(name != null),
|
||||
assert(codec != null);
|
||||
|
||||
/// The logical channel on which communication happens.
|
||||
///
|
||||
@ -108,7 +108,7 @@ class _EventChannelHandler<T> {
|
||||
this.codec,
|
||||
this.controller,
|
||||
this.messenger,
|
||||
) : assert(messenger != null); // ignore: unnecessary_null_comparison
|
||||
) : assert(messenger != null);
|
||||
|
||||
final String name;
|
||||
final MethodCodec codec;
|
||||
|
@ -205,7 +205,7 @@ class PluginRegistry extends Registrar {
|
||||
'This feature was deprecated after v1.26.0-18.0.pre.'
|
||||
)
|
||||
BinaryMessenger? binaryMessenger,
|
||||
]) : super(); // ignore: avoid_unused_constructor_parameters
|
||||
]) : super();
|
||||
|
||||
/// Returns `this`. The argument is ignored.
|
||||
@Deprecated(
|
||||
|
@ -5,7 +5,7 @@
|
||||
@TestOn('chrome') // Uses web-only Flutter SDK
|
||||
|
||||
import 'dart:async';
|
||||
import 'dart:ui' as ui; // ignore: unused_import, it looks unused as web-only elements are the only elements used.
|
||||
import 'dart:ui' as ui;
|
||||
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:flutter_test/flutter_test.dart';
|
||||
|
@ -4,7 +4,7 @@
|
||||
|
||||
@TestOn('chrome') // Uses web-only Flutter SDK
|
||||
|
||||
import 'dart:ui' as ui; // ignore: unused_import, it looks unused as web-only elements are the only elements used.
|
||||
import 'dart:ui' as ui;
|
||||
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:flutter_test/flutter_test.dart';
|
||||
|
@ -157,9 +157,6 @@ class DartVm {
|
||||
///
|
||||
/// After this function completes this object is no longer usable.
|
||||
Future<void> stop() async {
|
||||
// TODO(dnfield): Remove ignore once internal repo is up to date
|
||||
// https://github.com/flutter/flutter/issues/74518
|
||||
// ignore: await_only_futures
|
||||
await _vmService.dispose();
|
||||
await _vmService.onDone;
|
||||
}
|
||||
|
@ -22,7 +22,6 @@ void registerWebServiceExtension(
|
||||
Future<Map<String, dynamic>> Function(Map<String, String>) call) {
|
||||
js_util.setProperty(html.window, r'$flutterDriver',
|
||||
allowInterop((dynamic message) async {
|
||||
// ignore: undefined_function, undefined_identifier
|
||||
final Map<String, String> params = Map<String, String>.from(
|
||||
jsonDecode(message as String) as Map<String, dynamic>);
|
||||
final Map<String, dynamic> result =
|
||||
|
@ -202,7 +202,7 @@ class IntegrationTestWidgetsFlutterBinding extends LiveTestWidgetsFlutterBinding
|
||||
List<String> streams = const <String>['all'],
|
||||
@visibleForTesting vm.VmService? vmService,
|
||||
}) async {
|
||||
assert(streams != null); // ignore: unnecessary_null_comparison
|
||||
assert(streams != null);
|
||||
assert(streams.isNotEmpty);
|
||||
if (vmService != null) {
|
||||
_vmService = vmService;
|
||||
|
@ -32,7 +32,7 @@ Future<void> writeResponseData(
|
||||
String testOutputFilename = 'integration_response_data',
|
||||
String? destinationDirectory,
|
||||
}) async {
|
||||
assert(testOutputFilename != null); // ignore: unnecessary_null_comparison
|
||||
assert(testOutputFilename != null);
|
||||
destinationDirectory ??= testOutputsDirectory;
|
||||
await fs.directory(destinationDirectory).create(recursive: true);
|
||||
final File file = fs.file(path.join(
|
||||
|
Loading…
x
Reference in New Issue
Block a user