Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(164)

Unified Diff: pkg/analysis_server/test/channel/byte_stream_channel_test.dart

Issue 2991773002: Replace typed_mock with mockito in analysis_server. (Closed)
Patch Set: Created 3 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « pkg/analysis_server/test/analysis/update_content_test.dart ('k') | pkg/analysis_server/test/mocks.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analysis_server/test/channel/byte_stream_channel_test.dart
diff --git a/pkg/analysis_server/test/channel/byte_stream_channel_test.dart b/pkg/analysis_server/test/channel/byte_stream_channel_test.dart
index 8b4693a4931819c28e28ea746b972c1ad3002f17..4395c7ab08d03fb6ed5d44615851eed3b149bf34 100644
--- a/pkg/analysis_server/test/channel/byte_stream_channel_test.dart
+++ b/pkg/analysis_server/test/channel/byte_stream_channel_test.dart
@@ -9,9 +9,9 @@ import 'dart:io';
import 'package:analysis_server/protocol/protocol.dart';
import 'package:analysis_server/src/channel/byte_stream_channel.dart';
import 'package:analyzer/instrumentation/instrumentation.dart';
+import 'package:mockito/mockito.dart';
import 'package:test/test.dart';
import 'package:test_reflective_loader/test_reflective_loader.dart';
-import 'package:typed_mock/typed_mock.dart';
import '../mocks.dart';
@@ -240,7 +240,7 @@ class ByteStreamServerChannelTest {
test_sendNotification_exceptionInSink() async {
// This IOSink asynchronously throws an exception on any writeln().
var outputSink = new _IOSinkMock();
- when(outputSink.writeln(anyObject)).thenInvoke((object) {
+ when(outputSink.writeln(any)).thenAnswer((answer) {
new Timer(new Duration(milliseconds: 10), () {
throw '42';
});
@@ -269,4 +269,4 @@ class ByteStreamServerChannelTest {
}
}
-class _IOSinkMock extends TypedMock implements IOSink {}
+class _IOSinkMock extends Mock implements IOSink {}
« no previous file with comments | « pkg/analysis_server/test/analysis/update_content_test.dart ('k') | pkg/analysis_server/test/mocks.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698