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

Unified Diff: chrome/test/ui/ppapi_uitest.cc

Issue 9564024: Re-land http://codereview.chromium.org/9403039/, r124106 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: remove unnecessary change to ppapi_uitest.cc timer_ Created 8 years, 9 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 | « no previous file | ppapi/tests/test_case.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/ui/ppapi_uitest.cc
diff --git a/chrome/test/ui/ppapi_uitest.cc b/chrome/test/ui/ppapi_uitest.cc
index 69fa0316d228cbfef4188979ab4a3f5a86f01357..2993e9d58d1174ffbe35a69e6b91316e86cc8507 100644
--- a/chrome/test/ui/ppapi_uitest.cc
+++ b/chrome/test/ui/ppapi_uitest.cc
@@ -155,6 +155,15 @@ class PPAPITestBase : public InProcessBrowserTest {
RunTestURL(url);
}
+ // Run the test and reload. This can test for clean shutdown, including leaked
+ // instance object vars.
+ void RunTestAndReload(const std::string& test_case) {
+ GURL url = GetTestFileUrl(test_case);
+ RunTestURL(url);
+ // If that passed, we simply run the test again, which navigates again.
+ RunTestURL(url);
+ }
+
void RunTestViaHTTP(const std::string& test_case) {
// For HTTP tests, we use the output DIR to grab the generated files such
// as the NEXEs.
@@ -442,10 +451,25 @@ TEST_PPAPI_OUT_OF_PROCESS(MAYBE_InputEvent)
// TODO(bbudge) Enable when input events are proxied correctly for NaCl.
TEST_PPAPI_NACL_VIA_HTTP(DISABLED_InputEvent)
-TEST_PPAPI_IN_PROCESS(Instance)
-TEST_PPAPI_OUT_OF_PROCESS(Instance)
-// The Instance test is actually InstanceDeprecated which isn't supported
-// by NaCl.
+TEST_PPAPI_IN_PROCESS(Instance_ExecuteScript);
+TEST_PPAPI_OUT_OF_PROCESS(Instance_ExecuteScript)
+// ExecuteScript isn't supported by NaCl.
+
+// We run and reload the RecursiveObjects test to ensure that the InstanceObject
+// (and others) are properly cleaned up after the first run.
+IN_PROC_BROWSER_TEST_F(PPAPITest, Instance_RecursiveObjects) {
+ RunTestAndReload("Instance_RecursiveObjects");
+}
+// TODO(dmichael): Make it work out-of-process (or at least see whether we
+// care).
+IN_PROC_BROWSER_TEST_F(OutOfProcessPPAPITest,
+ DISABLED_Instance_RecursiveObjects) {
+ RunTestAndReload("Instance_RecursiveObjects");
+}
+TEST_PPAPI_IN_PROCESS(Instance_TestLeakedObjectDestructors);
+TEST_PPAPI_OUT_OF_PROCESS(Instance_TestLeakedObjectDestructors);
+// ScriptableObjects aren't supported in NaCl, so Instance_RecursiveObjects and
+// Instance_TestLeakedObjectDestructors don't make sense for NaCl.
TEST_PPAPI_IN_PROCESS(Graphics2D)
TEST_PPAPI_OUT_OF_PROCESS(Graphics2D)
« no previous file with comments | « no previous file | ppapi/tests/test_case.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698