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

Unified Diff: runtime/vm/message_handler_test.cc

Issue 1122503003: Display isolate message queue in Observatory debugger (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 8 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 | « runtime/vm/message_handler.cc ('k') | runtime/vm/message_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/message_handler_test.cc
diff --git a/runtime/vm/message_handler_test.cc b/runtime/vm/message_handler_test.cc
index 81325117bb00ee7ce3e022c5c72c8042298f5726..7bfcb9aa557d851cfc658a40d22ac262e16ceb32 100644
--- a/runtime/vm/message_handler_test.cc
+++ b/runtime/vm/message_handler_test.cc
@@ -158,11 +158,25 @@ UNIT_TEST_CASE(MessageHandler_HasOOBMessages) {
Message* message = new Message(1, NULL, 0, Message::kNormalPriority);
handler_peer.PostMessage(message);
EXPECT(!handler.HasOOBMessages());
+ {
+ // Acquire ownership of message handler queues, verify one regular message.
+ MessageHandler::AcquiredQueues aq;
+ handler.AcquireQueues(&aq);
+ EXPECT(aq.queue()->Length() == 1);
+ }
// Post an oob message.
message = new Message(1, NULL, 0, Message::kOOBPriority);
handler_peer.PostMessage(message);
EXPECT(handler.HasOOBMessages());
+ {
+ // Acquire ownership of message handler queues, verify one regular and one
+ // OOB message.
+ MessageHandler::AcquiredQueues aq;
+ handler.AcquireQueues(&aq);
+ EXPECT(aq.queue()->Length() == 1);
+ EXPECT(aq.oob_queue()->Length() == 1);
+ }
// Delete all pending messages.
handler_peer.CloseAllPorts();
« no previous file with comments | « runtime/vm/message_handler.cc ('k') | runtime/vm/message_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698