Drive: Add BatchableRequest subclass.
[chromium-blink-merge.git] / ppapi / tests / test_var_deprecated.h
blob26180a61098efe48e2b3f9427d5902a98c3ac5dd
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef PPAPI_TEST_TEST_VAR_DEPRECATED_H_
6 #define PPAPI_TEST_TEST_VAR_DEPRECATED_H_
8 #include <string>
10 #include "ppapi/c/dev/ppb_var_deprecated.h"
11 #include "ppapi/cpp/private/var_private.h"
12 #include "ppapi/tests/test_case.h"
14 class TestVarDeprecated : public TestCase {
15 public:
16 explicit TestVarDeprecated(TestingInstance* instance) : TestCase(instance) {}
18 // TestCase implementation.
19 virtual bool Init();
20 virtual void RunTests(const std::string& filter);
22 void set_var_from_page(const pp::VarPrivate& v) { var_from_page_ = v; }
24 protected:
25 // Test case protected overrides.
26 virtual pp::deprecated::ScriptableObject* CreateTestObject();
28 private:
29 std::string TestBasicString();
30 std::string TestInvalidAndEmpty();
31 std::string TestInvalidUtf8();
32 std::string TestNullInputInUtf8Conversion();
33 std::string TestValidUtf8();
34 std::string TestUtf8WithEmbeddedNulls();
35 std::string TestVarToUtf8ForWrongType();
36 std::string TestHasPropertyAndMethod();
37 std::string TestPassReference();
39 // Used by the tests that access the C API directly.
40 const PPB_Var_Deprecated* var_interface_;
42 // Saves the var from when a value is set on the test from the page.
43 pp::VarPrivate var_from_page_;
46 #endif // PPAPI_TEST_TEST_VAR_DEPRECATED_H_