Chromium Code Reviews| OLD | NEW |
|---|---|
| 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 CHROME_BROWSER_EXTENSIONS_EXTENSION_RECORD_API_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_RECORD_API_H_ |
| 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_RECORD_API_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_RECORD_API_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "chrome/browser/extensions/extension_function.h" | 9 #include "chrome/browser/extensions/extension_function.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 83 // possibly other data by posting them to text files. ReadReplyFiles | 83 // possibly other data by posting them to text files. ReadReplyFiles |
| 84 // collects these data for return to the JS side caller. | 84 // collects these data for return to the JS side caller. |
| 85 virtual void ReadReplyFiles() {} | 85 virtual void ReadReplyFiles() {} |
| 86 | 86 |
| 87 // Return the values gathered in RunTestBrowser. No common code here; all | 87 // Return the values gathered in RunTestBrowser. No common code here; all |
| 88 // logic is in subclasses. | 88 // logic is in subclasses. |
| 89 virtual void Finish() {} | 89 virtual void Finish() {} |
| 90 | 90 |
| 91 FilePath user_data_dir_; | 91 FilePath user_data_dir_; |
| 92 std::string url_contents_; | 92 std::string url_contents_; |
| 93 int repeat_count_; | |
|
Aaron Boodman
2012/06/05 04:17:04
Why does capture need the concept of 'repeat count
clintstaley
2012/06/05 20:46:08
Because of the vagaries of the record mode and pla
| |
| 93 std::vector<std::string> errors_; | 94 std::vector<std::string> errors_; |
| 94 | 95 |
| 95 // Base CommandLine on which to build the test browser CommandLine | 96 // Base CommandLine on which to build the test browser CommandLine |
| 96 CommandLine base_command_line_; | 97 CommandLine base_command_line_; |
| 97 | 98 |
| 98 // ProcessStrategy to use for this run. | 99 // ProcessStrategy to use for this run. |
| 99 scoped_ptr<ProcessStrategy> process_strategy_; | 100 scoped_ptr<ProcessStrategy> process_strategy_; |
| 100 }; | 101 }; |
| 101 | 102 |
| 102 class CaptureURLsFunction : public RunPageCyclerFunction { | 103 class CaptureURLsFunction : public RunPageCyclerFunction { |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 136 virtual void AddSwitches(CommandLine* command_line) OVERRIDE; | 137 virtual void AddSwitches(CommandLine* command_line) OVERRIDE; |
| 137 | 138 |
| 138 // Read stats file. | 139 // Read stats file. |
| 139 virtual void ReadReplyFiles() OVERRIDE; | 140 virtual void ReadReplyFiles() OVERRIDE; |
| 140 | 141 |
| 141 // Return error list, statistical results, and runtime. | 142 // Return error list, statistical results, and runtime. |
| 142 virtual void Finish() OVERRIDE; | 143 virtual void Finish() OVERRIDE; |
| 143 | 144 |
| 144 // These three data are additional information added to the sub-browser | 145 // These three data are additional information added to the sub-browser |
| 145 // commandline. | 146 // commandline. |
| 146 int repeat_count_; | |
| 147 FilePath extension_path_; | 147 FilePath extension_path_; |
| 148 FilePath stats_file_path_; | 148 FilePath stats_file_path_; |
| 149 | 149 |
| 150 // This time datum marks the start and end of the sub-browser run. | 150 // This time datum marks the start and end of the sub-browser run. |
| 151 base::Time timer_; | 151 base::Time timer_; |
| 152 | 152 |
| 153 // These two data are additional information returned to caller. | 153 // These two data are additional information returned to caller. |
| 154 int run_time_ms_; | 154 int run_time_ms_; |
| 155 std::string stats_; | 155 std::string stats_; |
| 156 }; | 156 }; |
| 157 | 157 |
| 158 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_RECORD_API_H_ | 158 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_RECORD_API_H_ |
| OLD | NEW |