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

Unified Diff: runtime/vm/service_test.cc

Issue 1120133002: Rework error handling in the service protocol and in Observatory. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 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
« runtime/vm/service.cc ('K') | « runtime/vm/service.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/service_test.cc
diff --git a/runtime/vm/service_test.cc b/runtime/vm/service_test.cc
index fd3ec237f7f9267dfd3572cbac09bf71349c67be..7751eceb2d9c4ad488d3614d5012a060c72f1dbc 100644
--- a/runtime/vm/service_test.cc
+++ b/runtime/vm/service_test.cc
@@ -160,7 +160,7 @@ TEST_CASE(Service_Code) {
Eval(lib, "[0, port, '0', 'getObject', ['objectId'], ['code/0']]");
Service::HandleIsolateMessage(isolate, service_msg);
handler.HandleNextMessage();
- EXPECT_SUBSTRING("\"type\":\"Error\"", handler.msg());
+ EXPECT_SUBSTRING("\"error\"", handler.msg());
// The following test checks that a code object can be found only
// at compile_timestamp()-code.EntryPoint().
@@ -190,7 +190,7 @@ TEST_CASE(Service_Code) {
address);
Service::HandleIsolateMessage(isolate, service_msg);
handler.HandleNextMessage();
- EXPECT_SUBSTRING("\"type\":\"Error\"", handler.msg());
+ EXPECT_SUBSTRING("\"error\"", handler.msg());
// Request code object at (compile_timestamp - 1)-code.EntryPoint()
// Expect this to fail because the timestamp is wrong.
@@ -201,7 +201,7 @@ TEST_CASE(Service_Code) {
address);
Service::HandleIsolateMessage(isolate, service_msg);
handler.HandleNextMessage();
- EXPECT_SUBSTRING("\"type\":\"Error\"", handler.msg());
+ EXPECT_SUBSTRING("\"error\"", handler.msg());
// Request native code at address. Expect the null code object back.
address = last;
@@ -220,7 +220,7 @@ TEST_CASE(Service_Code) {
address);
Service::HandleIsolateMessage(isolate, service_msg);
handler.HandleNextMessage();
- EXPECT_SUBSTRING("\"type\":\"Error\"", handler.msg());
+ EXPECT_SUBSTRING("\"error\"", handler.msg());
}
@@ -575,7 +575,7 @@ TEST_CASE(Service_Profile) {
Service::HandleIsolateMessage(isolate, service_msg);
handler.HandleNextMessage();
// Expect error (tags required).
- EXPECT_SUBSTRING("\"type\":\"Error\"", handler.msg());
+ EXPECT_SUBSTRING("\"error\"", handler.msg());
service_msg =
Eval(lib, "[0, port, '0', 'getCpuProfile', ['tags'], ['None']]");
@@ -589,7 +589,7 @@ TEST_CASE(Service_Profile) {
Service::HandleIsolateMessage(isolate, service_msg);
handler.HandleNextMessage();
// Expect error.
- EXPECT_SUBSTRING("\"type\":\"Error\"", handler.msg());
+ EXPECT_SUBSTRING("\"error\"", handler.msg());
}
#endif // !defined(TARGET_ARCH_ARM64)
« runtime/vm/service.cc ('K') | « runtime/vm/service.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698