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

Unified Diff: ppapi/tests/test_post_message.h

Issue 7821001: Add test for calling PostMessage during Init. Deflakify TestPostMessage. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Turn down thread & message count to reduce flakiness Created 9 years, 4 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 | « chrome/test/ui/ppapi_uitest.cc ('k') | ppapi/tests/test_post_message.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/tests/test_post_message.h
diff --git a/ppapi/tests/test_post_message.h b/ppapi/tests/test_post_message.h
index f0818809067aab73435bedfc2f69546c845e10e5..af1dc3621bc9f579c84f36987d52bb5324f04ff5 100644
--- a/ppapi/tests/test_post_message.h
+++ b/ppapi/tests/test_post_message.h
@@ -12,7 +12,8 @@
class TestPostMessage : public TestCase {
public:
- explicit TestPostMessage(TestingInstance* instance) : TestCase(instance) {}
+ explicit TestPostMessage(TestingInstance* instance);
+ virtual ~TestPostMessage();
private:
// TestCase implementation.
@@ -38,6 +39,15 @@ class TestPostMessage : public TestCase {
// Returns true on success, false on failure.
bool ClearListeners();
+ // Wait for pending messages; return the number of messages that were pending
+ // at the time of invocation.
+ int WaitForMessages();
+
+ // Test that we can send a message from Instance::Init. Note the actual
+ // message is sent in TestPostMessage::Init, and this test simply makes sure
+ // we got it.
+ std::string TestSendInInit();
+
// Test some basic functionality; make sure we can send data successfully
// in both directions.
std::string TestSendingData();
« no previous file with comments | « chrome/test/ui/ppapi_uitest.cc ('k') | ppapi/tests/test_post_message.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698