OLD | NEW |
1 // Copyright (c) 2006-2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2009 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 #include <fstream> | 5 #include <fstream> |
6 #include <string> | 6 #include <string> |
7 #include <vector> | 7 #include <vector> |
8 | 8 |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/file_util.h" | 10 #include "base/file_util.h" |
(...skipping 301 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
312 } else if (LowerCaseEqualsASCII(action, "clearbrowsingdata")) { | 312 } else if (LowerCaseEqualsASCII(action, "clearbrowsingdata")) { |
313 did_complete_action = OpenClearBrowsingDataDialog(); | 313 did_complete_action = OpenClearBrowsingDataDialog(); |
314 } else if (LowerCaseEqualsASCII(action, "crash")) { | 314 } else if (LowerCaseEqualsASCII(action, "crash")) { |
315 did_complete_action = ForceCrash(); | 315 did_complete_action = ForceCrash(); |
316 } else if (LowerCaseEqualsASCII(action, "dialog")) { | 316 } else if (LowerCaseEqualsASCII(action, "dialog")) { |
317 did_complete_action = ExerciseDialog(); | 317 did_complete_action = ExerciseDialog(); |
318 } else if (LowerCaseEqualsASCII(action, "downarrow")) { | 318 } else if (LowerCaseEqualsASCII(action, "downarrow")) { |
319 did_complete_action = PressDownArrow(); | 319 did_complete_action = PressDownArrow(); |
320 } else if (LowerCaseEqualsASCII(action, "downloads")) { | 320 } else if (LowerCaseEqualsASCII(action, "downloads")) { |
321 did_complete_action = ShowDownloads(); | 321 did_complete_action = ShowDownloads(); |
322 // TODO(estade): port. | |
323 #if defined(OS_WIN) | |
324 } else if (LowerCaseEqualsASCII(action, "dragtableft")) { | 322 } else if (LowerCaseEqualsASCII(action, "dragtableft")) { |
325 did_complete_action = DragActiveTab(false); | 323 did_complete_action = DragActiveTab(false); |
326 } else if (LowerCaseEqualsASCII(action, "dragtabout")) { | 324 } else if (LowerCaseEqualsASCII(action, "dragtabout")) { |
327 did_complete_action = DragTabOut(); | 325 did_complete_action = DragTabOut(); |
328 } else if (LowerCaseEqualsASCII(action, "dragtabright")) { | 326 } else if (LowerCaseEqualsASCII(action, "dragtabright")) { |
329 did_complete_action = DragActiveTab(true); | 327 did_complete_action = DragActiveTab(true); |
330 #endif // defined(OS_WIN) | |
331 } else if (LowerCaseEqualsASCII(action, "duplicatetab")) { | 328 } else if (LowerCaseEqualsASCII(action, "duplicatetab")) { |
332 did_complete_action = DuplicateTab(); | 329 did_complete_action = DuplicateTab(); |
333 } else if (LowerCaseEqualsASCII(action, "editsearchengines")) { | 330 } else if (LowerCaseEqualsASCII(action, "editsearchengines")) { |
334 did_complete_action = OpenEditSearchEnginesDialog(); | 331 did_complete_action = OpenEditSearchEnginesDialog(); |
335 } else if (LowerCaseEqualsASCII(action, "findinpage")) { | 332 } else if (LowerCaseEqualsASCII(action, "findinpage")) { |
336 did_complete_action = FindInPage(); | 333 did_complete_action = FindInPage(); |
337 } else if (LowerCaseEqualsASCII(action, "forward")) { | 334 } else if (LowerCaseEqualsASCII(action, "forward")) { |
338 did_complete_action = ForwardButton(); | 335 did_complete_action = ForwardButton(); |
339 } else if (LowerCaseEqualsASCII(action, "goofftherecord")) { | 336 } else if (LowerCaseEqualsASCII(action, "goofftherecord")) { |
340 did_complete_action = GoOffTheRecord(); | 337 did_complete_action = GoOffTheRecord(); |
(...skipping 412 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
753 } | 750 } |
754 } | 751 } |
755 | 752 |
756 TEST_F(AutomatedUITest, TheOneAndOnlyTest) { | 753 TEST_F(AutomatedUITest, TheOneAndOnlyTest) { |
757 const CommandLine& parsed_command_line = *CommandLine::ForCurrentProcess(); | 754 const CommandLine& parsed_command_line = *CommandLine::ForCurrentProcess(); |
758 if (parsed_command_line.HasSwitch(kReproSwitch)) | 755 if (parsed_command_line.HasSwitch(kReproSwitch)) |
759 RunReproduction(); | 756 RunReproduction(); |
760 else | 757 else |
761 RunAutomatedUITest(); | 758 RunAutomatedUITest(); |
762 } | 759 } |
OLD | NEW |