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

Unified Diff: pkg/analysis_server/test/analysis_server_test.dart

Issue 307533004: Send 'notification.errors' for all non-SDK files. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 7 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
Index: pkg/analysis_server/test/analysis_server_test.dart
diff --git a/pkg/analysis_server/test/analysis_server_test.dart b/pkg/analysis_server/test/analysis_server_test.dart
index 326ce3f679e18128bea92cf7ce95971243f30049..1a1ca89f79df9e2624de4cdfa20b0b5916b642cb 100644
--- a/pkg/analysis_server/test/analysis_server_test.dart
+++ b/pkg/analysis_server/test/analysis_server_test.dart
@@ -144,15 +144,15 @@ class AnalysisServerTest {
static void errorToJson_noCorrection() {
MockSource source = new MockSource();
- source.when(callsTo('get encoding')).alwaysReturn('foo.dart');
+ source.when(callsTo('get fullName')).alwaysReturn('foo.dart');
CompileTimeErrorCode errorCode =
CompileTimeErrorCode.CONST_CONSTRUCTOR_WITH_NON_CONST_SUPER;
AnalysisError analysisError =
new AnalysisError.con2(source, 10, 5, errorCode, ['Foo']);
Map<String, Object> json = AnalysisServer.errorToJson(analysisError);
expect(json, hasLength(5));
- expect(json['source'], equals('foo.dart'));
- expect(json['errorCode'], equals(errorCode.ordinal));
+ expect(json['file'], equals('foo.dart'));
+ expect(json['errorCode'], 'CompileTimeErrorCode.CONST_CONSTRUCTOR_WITH_NON_CONST_SUPER');
expect(json['offset'], equals(analysisError.offset));
expect(json['length'], equals(analysisError.length));
expect(json['message'], equals(errorCode.message.replaceAll('%s', 'Foo')));

Powered by Google App Engine
This is Rietveld 408576698