OLD | NEW |
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // Tests for CppBoundClass, in conjunction with CppBindingExample. Binds | 5 // Tests for CppBoundClass, in conjunction with CppBindingExample. Binds |
6 // a CppBindingExample class into JavaScript in a custom test shell and tests | 6 // a CppBindingExample class into JavaScript in a custom test shell and tests |
7 // the binding from the outside by loading JS into the shell. | 7 // the binding from the outside by loading JS into the shell. |
8 | 8 |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
11 #include "base/message_loop.h" | 11 #include "base/message_loop.h" |
| 12 #include "webkit/api/public/WebData.h" |
| 13 #include "webkit/api/public/WebURL.h" |
12 #include "webkit/glue/cpp_binding_example.h" | 14 #include "webkit/glue/cpp_binding_example.h" |
13 #include "webkit/glue/webkit_glue.h" | 15 #include "webkit/glue/webkit_glue.h" |
14 #include "webkit/glue/webframe.h" | 16 #include "webkit/glue/webframe.h" |
15 #include "webkit/glue/webview.h" | 17 #include "webkit/glue/webview.h" |
16 #include "webkit/tools/test_shell/test_shell_test.h" | 18 #include "webkit/tools/test_shell/test_shell_test.h" |
17 | 19 |
18 namespace { | 20 namespace { |
19 | 21 |
20 class CppBindingExampleSubObject : public CppBindingExample { | 22 class CppBindingExampleSubObject : public CppBindingExample { |
21 public: | 23 public: |
(...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
256 | 258 |
257 // Ensures existent methods can be invoked successfully when the fallback method | 259 // Ensures existent methods can be invoked successfully when the fallback method |
258 // is used | 260 // is used |
259 TEST_F(CppBoundClassWithFallbackMethodTest, | 261 TEST_F(CppBoundClassWithFallbackMethodTest, |
260 InvokeExistentMethodsWithFallback) { | 262 InvokeExistentMethodsWithFallback) { |
261 std::string js = BuildJSCondition("example.echoValue(34)", "34"); | 263 std::string js = BuildJSCondition("example.echoValue(34)", "34"); |
262 CheckJavaScriptSuccess(js); | 264 CheckJavaScriptSuccess(js); |
263 } | 265 } |
264 | 266 |
265 } // namespace | 267 } // namespace |
OLD | NEW |