Index: chrome/test/chromedriver/capabilities.h |
diff --git a/chrome/test/chromedriver/capabilities.h b/chrome/test/chromedriver/capabilities.h |
index 012d2f7fcf9262150fcc69ee6c8074aa447582ab..d4f180eb5b7744497056e2a132f9c6a4b4763775 100644 |
--- a/chrome/test/chromedriver/capabilities.h |
+++ b/chrome/test/chromedriver/capabilities.h |
@@ -5,6 +5,7 @@ |
#ifndef CHROME_TEST_CHROMEDRIVER_CAPABILITIES_H_ |
#define CHROME_TEST_CHROMEDRIVER_CAPABILITIES_H_ |
+#include <map> |
#include <set> |
#include <string> |
#include <vector> |
@@ -12,14 +13,43 @@ |
#include "base/command_line.h" |
#include "base/files/file_path.h" |
#include "base/memory/scoped_ptr.h" |
+#include "base/strings/string16.h" |
namespace base { |
class DictionaryValue; |
} |
+class CommandLine; |
class Log; |
class Status; |
+class Switches { |
+ public: |
+ typedef base::FilePath::StringType NativeString; |
+ Switches(); |
+ ~Switches(); |
+ |
+ void SetSwitch(const std::string& name); |
+ void SetSwitch(const std::string& name, const std::string& value); |
+ void SetSwitch(const std::string& name, const string16& value); |
+ void SetSwitch(const std::string& name, const base::FilePath& value); |
+ |
+ void SetUnparsedSwitch(const std::string& unparsed_switch); |
chrisgao (Use stgao instead)
2013/08/29 22:53:32
Add a comment on its difference from those above?
kkania
2013/08/30 03:14:57
Done.
|
+ |
+ bool HasSwitch(const std::string& name) const; |
+ std::string GetSwitchValue(const std::string& name) const; |
+ NativeString GetSwitchValueNative(const std::string& name) const; |
+ |
+ size_t GetSize() const; |
+ |
+ void AppendToCommandLine(CommandLine* command) const; |
+ std::string ToString() const; |
+ |
+ private: |
+ typedef std::map<std::string, NativeString> SwitchMap; |
+ SwitchMap switch_map_; |
+}; |
+ |
struct Capabilities { |
Capabilities(); |
~Capabilities(); |
@@ -48,10 +78,9 @@ struct Capabilities { |
std::string android_activity; |
std::string android_process; |
std::string android_device_serial; |
- std::string android_args; |
+ base::FilePath binary; |
std::string log_path; |
- CommandLine command; |
scoped_ptr<base::DictionaryValue> prefs; |
scoped_ptr<base::DictionaryValue> local_state; |
std::vector<std::string> extensions; |
@@ -60,6 +89,8 @@ struct Capabilities { |
// Set of switches which should be removed from default list when launching |
// Chrome. |
std::set<std::string> exclude_switches; |
chrisgao (Use stgao instead)
2013/08/29 22:53:32
exclude_switches has no effect anymore?
kkania
2013/08/30 03:14:57
Done.
|
+ |
+ Switches switches; |
}; |
#endif // CHROME_TEST_CHROMEDRIVER_CAPABILITIES_H_ |