Index: pkg/analysis_server/test/mocks.dart |
diff --git a/pkg/analysis_server/test/mocks.dart b/pkg/analysis_server/test/mocks.dart |
index 7b898cbd4f53e7f059cc18d9ae99b47d009dd36c..88a6744c908c20e1ab6b1d67540ac375126fee66 100644 |
--- a/pkg/analysis_server/test/mocks.dart |
+++ b/pkg/analysis_server/test/mocks.dart |
@@ -7,6 +7,9 @@ library mocks; |
import 'dart:async'; |
import 'dart:io'; |
+import 'package:analysis_server/src/channel.dart'; |
+import 'package:analysis_server/src/protocol.dart'; |
+ |
/** |
* A mock [WebSocket] for testing. |
*/ |
@@ -46,3 +49,20 @@ class MockSocket<T> implements WebSocket { |
noSuchMethod(Invocation invocation) => super.noSuchMethod(invocation); |
} |
+ |
+/** |
+ * A mock [ServerCommunicationChannel] channel that does nothing. |
+ */ |
+class MockServerChannel implements ServerCommunicationChannel { |
+ @override |
+ void listen(void onRequest(Request request), {void onError(), void onDone()}) { |
+ } |
+ |
+ @override |
+ void sendNotification(Notification notification) { |
+ } |
+ |
+ @override |
+ void sendResponse(Response response) { |
+ } |
+} |