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

Unified Diff: tests/ppapi_test_lib/test_interface.cc

Issue 7292002: Remove plugin connection to PPAPI scriptable objects (var deprecated). Also (Closed) Base URL: svn://svn.chromium.org/native_client/trunk/src/native_client/
Patch Set: '' Created 9 years, 5 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 | « tests/ppapi_test_lib/test_interface.h ('k') | tests/pyauto_nacl/multiple_nexes.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/ppapi_test_lib/test_interface.cc
===================================================================
--- tests/ppapi_test_lib/test_interface.cc (revision 6005)
+++ tests/ppapi_test_lib/test_interface.cc (working copy)
@@ -13,8 +13,6 @@
#include "native_client/tests/ppapi_test_lib/get_browser_interface.h"
#include "native_client/tests/ppapi_test_lib/internal_utils.h"
-#include "ppapi/c/dev/ppb_var_deprecated.h"
-
#include "ppapi/c/pp_instance.h"
#include "ppapi/c/pp_module.h"
#include "ppapi/c/pp_var.h"
@@ -47,13 +45,6 @@
return &table;
}
- void AddScriptableTest(nacl::string test_name,
- ScriptableTestFunction test_function) {
- scriptable_test_map_[test_name] = test_function;
- }
- bool HasScriptableTest(nacl::string test_name);
- PP_Var RunScriptableTest(nacl::string test_name);
-
void AddTest(nacl::string test_name, TestFunction test_function) {
test_map_[test_name] = test_function;
}
@@ -64,26 +55,10 @@
TestTable() {}
- typedef std::map<nacl::string, ScriptableTestFunction> ScriptableTestMap;
- ScriptableTestMap scriptable_test_map_; // DEPRECATED.
typedef std::map<nacl::string, TestFunction> TestMap;
TestMap test_map_;
};
-bool TestTable::HasScriptableTest(nacl::string test_name) {
- ScriptableTestMap::iterator it = scriptable_test_map_.find(test_name);
- return it != scriptable_test_map_.end();
-}
-
-PP_Var TestTable::RunScriptableTest(nacl::string test_name) {
- ScriptableTestMap::iterator it = scriptable_test_map_.find(test_name);
- if (it == scriptable_test_map_.end())
- return PP_MakeUndefined();
- CHECK(it->second != NULL);
- ScriptableTestFunction test_function = it->second;
- return test_function();
-}
-
void TestTable::RunTest(nacl::string test_name) {
TestMap::iterator it = test_map_.find(test_name);
if (it == test_map_.end()) {
@@ -97,19 +72,6 @@
} // namespace
-void RegisterScriptableTest(nacl::string test_name,
- ScriptableTestFunction test_func) {
- TestTable::Get()->AddScriptableTest(test_name, test_func);
-}
-
-bool HasScriptableTest(nacl::string test_name) {
- return TestTable::Get()->HasScriptableTest(test_name);
-}
-
-PP_Var RunScriptableTest(nacl::string test_name) {
- return TestTable::Get()->RunScriptableTest(test_name);
-}
-
void RegisterTest(nacl::string test_name, TestFunction test_func) {
TestTable::Get()->AddTest(test_name, test_func);
}
@@ -133,17 +95,6 @@
PP_Var callback_var = PPBVar()->VarFromUtf8(pp_module(),
callback_name,
strlen(callback_name));
- // Report using synchronous scripting for sync tests.
- // This is deprecated and will be removed shortly.
-#ifndef PPAPI_INSTANCE_REMOVE_SCRIPTING
- PP_Var window = PPBInstance()->GetWindowObject(pp_instance());
- CHECK(window.type == PP_VARTYPE_OBJECT);
-
- PP_Var exception = PP_MakeUndefined();
- PPBVarDeprecated()->Call(window, callback_var, 0, NULL, &exception);
- PPBVarDeprecated()->Release(window);
-#endif
-
// Report using postmessage for async tests.
PPBMessaging()->PostMessage(pp_instance(), callback_var);
PPBVar()->Release(callback_var);
« no previous file with comments | « tests/ppapi_test_lib/test_interface.h ('k') | tests/pyauto_nacl/multiple_nexes.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698