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

Side by Side Diff: content/shell/webkit_test_runner.h

Issue 11316244: [content shell] add support for a testRunner.setXSSAuditorEnabled (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 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 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 #ifndef CONTENT_SHELL_WEBKIT_TEST_RUNNER_H_ 5 #ifndef CONTENT_SHELL_WEBKIT_TEST_RUNNER_H_
6 #define CONTENT_SHELL_WEBKIT_TEST_RUNNER_H_ 6 #define CONTENT_SHELL_WEBKIT_TEST_RUNNER_H_
7 7
8 #include "base/file_path.h" 8 #include "base/file_path.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "content/public/renderer/render_view_observer.h" 10 #include "content/public/renderer/render_view_observer.h"
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 virtual void printMessage(const std::string& message); 52 virtual void printMessage(const std::string& message);
53 virtual void postTask(WebTestRunner::WebTask* task); 53 virtual void postTask(WebTestRunner::WebTask* task);
54 virtual void postDelayedTask(WebTestRunner::WebTask* task, 54 virtual void postDelayedTask(WebTestRunner::WebTask* task,
55 long long ms); 55 long long ms);
56 virtual WebKit::WebString registerIsolatedFileSystem( 56 virtual WebKit::WebString registerIsolatedFileSystem(
57 const WebKit::WebVector<WebKit::WebString>& absolute_filenames); 57 const WebKit::WebVector<WebKit::WebString>& absolute_filenames);
58 virtual long long getCurrentTimeInMillisecond(); 58 virtual long long getCurrentTimeInMillisecond();
59 virtual WebKit::WebString getAbsoluteWebStringFromUTF8Path( 59 virtual WebKit::WebString getAbsoluteWebStringFromUTF8Path(
60 const std::string& utf8_path); 60 const std::string& utf8_path);
61 61
62 void Reset();
62 void Display(); 63 void Display();
64 void SetXSSAuditorEnabled(bool enabled);
63 65
64 void set_proxy(WebTestRunner::WebTestProxyBase* proxy) { proxy_ = proxy; } 66 void set_proxy(WebTestRunner::WebTestProxyBase* proxy) { proxy_ = proxy; }
65 67
66 private: 68 private:
67 // Message handlers. 69 // Message handlers.
68 void OnCaptureTextDump(bool as_text, bool printing, bool recursive); 70 void OnCaptureTextDump(bool as_text, bool printing, bool recursive);
69 void OnCaptureImageDump(const std::string& expected_pixel_hash); 71 void OnCaptureImageDump(const std::string& expected_pixel_hash);
70 void OnSetCurrentWorkingDirectory(const FilePath& current_working_directory); 72 void OnSetCurrentWorkingDirectory(const FilePath& current_working_directory);
71 73
72 SkCanvas* GetCanvas(); 74 SkCanvas* GetCanvas();
73 void PaintRect(const WebKit::WebRect& rect); 75 void PaintRect(const WebKit::WebRect& rect);
74 void PaintInvalidatedRegion(); 76 void PaintInvalidatedRegion();
75 void DisplayRepaintMask(); 77 void DisplayRepaintMask();
76 78
77 scoped_ptr<SkCanvas> canvas_; 79 scoped_ptr<SkCanvas> canvas_;
78 scoped_ptr<WebKit::WebContextMenuData> last_context_menu_data_; 80 scoped_ptr<WebKit::WebContextMenuData> last_context_menu_data_;
79 FilePath current_working_directory_; 81 FilePath current_working_directory_;
80 82
81 WebTestRunner::WebTestProxyBase* proxy_; 83 WebTestRunner::WebTestProxyBase* proxy_;
82 84
83 85
84 DISALLOW_COPY_AND_ASSIGN(WebKitTestRunner); 86 DISALLOW_COPY_AND_ASSIGN(WebKitTestRunner);
85 }; 87 };
86 88
87 } // namespace content 89 } // namespace content
88 90
89 #endif // CONTENT_SHELL_WEBKIT_TEST_RUNNER_H_ 91 #endif // CONTENT_SHELL_WEBKIT_TEST_RUNNER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698