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

Unified Diff: webkit/support/test_webkit_platform_support.h

Issue 12220091: Add implementations of WebKit::Platform testing APIs to TestWebKitPlatformSupport (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: with compile guard for WebUnitTestSupport.h Created 7 years, 10 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 | webkit/support/test_webkit_platform_support.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/support/test_webkit_platform_support.h
diff --git a/webkit/support/test_webkit_platform_support.h b/webkit/support/test_webkit_platform_support.h
index bb92e613d446d8a1bbce9c203e78196c37aafe2f..d55a070d530594e6df323b774c2187cbec73c288 100644
--- a/webkit/support/test_webkit_platform_support.h
+++ b/webkit/support/test_webkit_platform_support.h
@@ -19,6 +19,10 @@
#include "webkit/tools/test_shell/simple_webcookiejar_impl.h"
#include "webkit/tools/test_shell/test_shell_webmimeregistry_impl.h"
+#if HAVE_WEBUNITTESTSUPPORT
+#include "third_party/WebKit/Source/Platform/chromium/public/WebUnitTestSupport.h"
+#endif
+
class TestShellWebBlobRegistryImpl;
namespace WebKit {
@@ -29,6 +33,9 @@ typedef struct _HyphenDict HyphenDict;
// An implementation of WebKitPlatformSupport for tests.
class TestWebKitPlatformSupport :
+#if HAVE_WEBUNITTESTSUPPORT
+ public NON_EXPORTED_BASE(WebKit::WebUnitTestSupport),
+#endif
public webkit_glue::WebKitPlatformSupportImpl {
public:
TestWebKitPlatformSupport(bool unit_test_mode,
@@ -134,6 +141,22 @@ class TestWebKitPlatformSupport :
const WebKit::WebFloatPoint& velocity,
const WebKit::WebSize& cumulative_scroll);
+#if HAVE_WEBUNITTESTSUPPORT
+ virtual WebKit::WebUnitTestSupport* unitTestSupport();
+#endif
+
+ // WebUnitTestSupport implementation
+ virtual void registerMockedURL(const WebKit::WebURL& url,
+ const WebKit::WebURLResponse& response,
+ const WebKit::WebString& filePath);
+ virtual void registerMockedErrorURL(const WebKit::WebURL& url,
+ const WebKit::WebURLResponse& response,
+ const WebKit::WebURLError& error);
+ virtual void unregisterMockedURL(const WebKit::WebURL& url);
+ virtual void unregisterAllMockedURLs();
+ virtual void serveAsynchronousMockedRequests();
+ virtual WebKit::WebString webKitRootDir();
+
private:
TestShellWebMimeRegistryImpl mime_registry_;
MockWebClipboardImpl mock_clipboard_;
« no previous file with comments | « no previous file | webkit/support/test_webkit_platform_support.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698