Enable strict-inference (#135043)
Avoids that dynamic accidentally sneaks in, see https://dart.dev/tools/analysis#enabling-additional-type-checks
This commit is contained in:
committed by
GitHub
parent
96a4ae9dc5
commit
b0a90aee17
@@ -80,7 +80,7 @@ void main () {
|
||||
|
||||
expect(iosDeployDebugger.logLines, emits('Did finish launching.'));
|
||||
expect(await iosDeployDebugger.launchAndAttach(), isTrue);
|
||||
await iosDeployDebugger.logLines.drain();
|
||||
await iosDeployDebugger.logLines.drain<Object?>();
|
||||
expect(processManager, hasNoRemainingExpectations);
|
||||
expect(appDeltaDirectory, exists);
|
||||
});
|
||||
@@ -141,7 +141,7 @@ void main () {
|
||||
'process detach',
|
||||
]));
|
||||
expect(await iosDeployDebugger.launchAndAttach(), isTrue);
|
||||
await logLines.drain();
|
||||
await logLines.drain<Object?>();
|
||||
|
||||
expect(logger.traceText, contains('PROCESS_STOPPED'));
|
||||
expect(logger.traceText, contains('thread backtrace all'));
|
||||
@@ -189,7 +189,7 @@ void main () {
|
||||
|
||||
expect(iosDeployDebugger.logLines, emitsDone);
|
||||
expect(await iosDeployDebugger.launchAndAttach(), isFalse);
|
||||
await iosDeployDebugger.logLines.drain();
|
||||
await iosDeployDebugger.logLines.drain<Object?>();
|
||||
});
|
||||
|
||||
testWithoutContext('app exit', () async {
|
||||
@@ -209,7 +209,7 @@ void main () {
|
||||
]));
|
||||
|
||||
expect(await iosDeployDebugger.launchAndAttach(), isTrue);
|
||||
await iosDeployDebugger.logLines.drain();
|
||||
await iosDeployDebugger.logLines.drain<Object?>();
|
||||
});
|
||||
|
||||
testWithoutContext('app crash', () async {
|
||||
@@ -239,7 +239,7 @@ void main () {
|
||||
]));
|
||||
|
||||
expect(await iosDeployDebugger.launchAndAttach(), isTrue);
|
||||
await iosDeployDebugger.logLines.drain();
|
||||
await iosDeployDebugger.logLines.drain<Object?>();
|
||||
|
||||
expect(logger.traceText, contains('Process 6156 stopped'));
|
||||
expect(logger.traceText, contains('thread backtrace all'));
|
||||
@@ -263,7 +263,7 @@ void main () {
|
||||
expect(iosDeployDebugger.logLines, emitsDone);
|
||||
|
||||
expect(await iosDeployDebugger.launchAndAttach(), isFalse);
|
||||
await iosDeployDebugger.logLines.drain();
|
||||
await iosDeployDebugger.logLines.drain<Object?>();
|
||||
});
|
||||
|
||||
testWithoutContext('no provisioning profile 1, stdout', () async {
|
||||
@@ -364,7 +364,7 @@ void main () {
|
||||
'Log on attach2',
|
||||
]));
|
||||
expect(await iosDeployDebugger.launchAndAttach(), isTrue);
|
||||
await logLines.drain();
|
||||
await logLines.drain<Object?>();
|
||||
|
||||
expect(LineSplitter.split(logger.traceText), containsOnce('Received logs from ios-deploy.'));
|
||||
});
|
||||
|
||||
@@ -19,7 +19,7 @@ abstract class DapTestServer {
|
||||
Future<void> stop();
|
||||
StreamSink<List<int>> get sink;
|
||||
Stream<List<int>> get stream;
|
||||
Function(String message)? onStderrOutput;
|
||||
void Function(String message)? onStderrOutput;
|
||||
}
|
||||
|
||||
/// An instance of a DAP server running in-process (to aid debugging).
|
||||
@@ -83,7 +83,7 @@ class OutOfProcessDapTestServer extends DapTestServer {
|
||||
.listen((String error) {
|
||||
logger?.call(error);
|
||||
if (!_isShuttingDown) {
|
||||
final Function(String message)? stderrHandler = onStderrOutput;
|
||||
final void Function(String message)? stderrHandler = onStderrOutput;
|
||||
if (stderrHandler != null) {
|
||||
stderrHandler(error);
|
||||
} else {
|
||||
|
||||
@@ -147,7 +147,7 @@ class FakeHttpClient implements HttpClient {
|
||||
bool Function(X509Certificate cert, String host, int port)? badCertificateCallback;
|
||||
|
||||
@override
|
||||
Function(String line)? keyLog;
|
||||
void Function(String line)? keyLog;
|
||||
|
||||
@override
|
||||
void close({bool force = false}) { }
|
||||
|
||||
Reference in New Issue
Block a user