OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_BROWSER_LAYOUT_TEST_BLINK_TEST_CONTROLLER_H_ | 5 #ifndef CONTENT_SHELL_BROWSER_LAYOUT_TEST_BLINK_TEST_CONTROLLER_H_ |
6 #define CONTENT_SHELL_BROWSER_LAYOUT_TEST_BLINK_TEST_CONTROLLER_H_ | 6 #define CONTENT_SHELL_BROWSER_LAYOUT_TEST_BLINK_TEST_CONTROLLER_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <memory> | 9 #include <memory> |
10 #include <ostream> | 10 #include <ostream> |
(...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
187 | 187 |
188 private: | 188 private: |
189 enum TestPhase { | 189 enum TestPhase { |
190 BETWEEN_TESTS, | 190 BETWEEN_TESTS, |
191 DURING_TEST, | 191 DURING_TEST, |
192 CLEAN_UP | 192 CLEAN_UP |
193 }; | 193 }; |
194 | 194 |
195 static BlinkTestController* instance_; | 195 static BlinkTestController* instance_; |
196 | 196 |
| 197 Shell* SecondaryWindow(); |
| 198 void LoadDevToolsJSTest(); |
197 void DiscardMainWindow(); | 199 void DiscardMainWindow(); |
198 | 200 |
199 // Message handlers. | 201 // Message handlers. |
200 void OnAudioDump(const std::vector<unsigned char>& audio_dump); | 202 void OnAudioDump(const std::vector<unsigned char>& audio_dump); |
201 void OnImageDump(const std::string& actual_pixel_hash, const SkBitmap& image); | 203 void OnImageDump(const std::string& actual_pixel_hash, const SkBitmap& image); |
202 void OnTextDump(const std::string& dump); | 204 void OnTextDump(const std::string& dump); |
203 void OnInitiateLayoutDump(); | 205 void OnInitiateLayoutDump(); |
204 void OnLayoutDumpResponse(RenderFrameHost* sender, const std::string& dump); | 206 void OnLayoutDumpResponse(RenderFrameHost* sender, const std::string& dump); |
205 void OnPrintMessageToStderr(const std::string& message); | 207 void OnPrintMessageToStderr(const std::string& message); |
206 void OnPrintMessage(const std::string& message); | 208 void OnPrintMessage(const std::string& message); |
(...skipping 20 matching lines...) Expand all Loading... |
227 void HandleLayoutTestControlError(RenderFrameHost* frame); | 229 void HandleLayoutTestControlError(RenderFrameHost* frame); |
228 | 230 |
229 void OnAllServiceWorkersCleared(); | 231 void OnAllServiceWorkersCleared(); |
230 | 232 |
231 std::unique_ptr<BlinkTestResultPrinter> printer_; | 233 std::unique_ptr<BlinkTestResultPrinter> printer_; |
232 | 234 |
233 base::FilePath current_working_directory_; | 235 base::FilePath current_working_directory_; |
234 base::FilePath temp_path_; | 236 base::FilePath temp_path_; |
235 | 237 |
236 Shell* main_window_; | 238 Shell* main_window_; |
| 239 Shell* secondary_window_; |
237 Shell* devtools_window_; | 240 Shell* devtools_window_; |
238 | 241 |
239 std::unique_ptr<LayoutTestDevToolsBindings> devtools_bindings_; | 242 std::unique_ptr<LayoutTestDevToolsBindings> devtools_bindings_; |
240 | 243 |
241 // The PID of the render process of the render view host of main_window_. | 244 // The PID of the render process of the render view host of main_window_. |
242 int current_pid_; | 245 int current_pid_; |
243 | 246 |
244 // Tracks if (during the current test) we have already sent *initial* test | 247 // Tracks if (during the current test) we have already sent *initial* test |
245 // configuration to a renderer process (*initial* test configuration is | 248 // configuration to a renderer process (*initial* test configuration is |
246 // associated with some steps that should only be executed *once* per test - | 249 // associated with some steps that should only be executed *once* per test - |
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
301 #endif | 304 #endif |
302 | 305 |
303 SEQUENCE_CHECKER(sequence_checker_); | 306 SEQUENCE_CHECKER(sequence_checker_); |
304 | 307 |
305 DISALLOW_COPY_AND_ASSIGN(BlinkTestController); | 308 DISALLOW_COPY_AND_ASSIGN(BlinkTestController); |
306 }; | 309 }; |
307 | 310 |
308 } // namespace content | 311 } // namespace content |
309 | 312 |
310 #endif // CONTENT_SHELL_BROWSER_LAYOUT_TEST_BLINK_TEST_CONTROLLER_H_ | 313 #endif // CONTENT_SHELL_BROWSER_LAYOUT_TEST_BLINK_TEST_CONTROLLER_H_ |
OLD | NEW |