diff options
author | nirnimesh@chromium.org <nirnimesh@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-06-28 22:04:00 +0000 |
---|---|---|
committer | nirnimesh@chromium.org <nirnimesh@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-06-28 22:04:00 +0000 |
commit | 44eed9ff188a565ebd56d6e1084921eaae4af98d (patch) | |
tree | b807e78f4c77fa6759d9cb8e260653bdd89e666f /chrome | |
parent | 479a85d400996001fc4bc3cf4e471f39b0cdf4ac (diff) | |
download | chromium_src-44eed9ff188a565ebd56d6e1084921eaae4af98d.zip chromium_src-44eed9ff188a565ebd56d6e1084921eaae4af98d.tar.gz chromium_src-44eed9ff188a565ebd56d6e1084921eaae4af98d.tar.bz2 |
PyAuto: Collect branding info as a part of GetBrowserInfo()
Also, use command_line_string() from base/command_line.h which is
cross-platform now.
Review URL: http://codereview.chromium.org/2800029
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@51055 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
-rw-r--r-- | chrome/browser/automation/automation_provider.cc | 13 | ||||
-rw-r--r-- | chrome/test/pyautolib/pyauto.py | 3 |
2 files changed, 11 insertions, 5 deletions
diff --git a/chrome/browser/automation/automation_provider.cc b/chrome/browser/automation/automation_provider.cc index 621c80c..df2cf14 100644 --- a/chrome/browser/automation/automation_provider.cc +++ b/chrome/browser/automation/automation_provider.cc @@ -1641,13 +1641,18 @@ void AutomationProvider::GetBrowserInfo(Browser* browser, chrome::kBrowserProcessExecutablePath); properties->SetString(L"HelperProcessExecutablePath", chrome::kHelperProcessExecutablePath); -#if defined(OS_WIN) properties->SetString(L"command_line_string", CommandLine::ForCurrentProcess()->command_line_string()); -#elif defined(OS_POSIX) - properties->SetString(L"command_line_string", - JoinString(CommandLine::ForCurrentProcess()->argv(), ' ')); + + std::string branding; +#if defined(GOOGLE_CHROME_BUILD) + branding = "Google Chrome"; +#elif defined(CHROMIUM_BUILD) + branding = "Chromium"; +#else + branding = "Unknown Branding"; #endif + properties->SetString(L"branding", branding); scoped_ptr<DictionaryValue> return_value(new DictionaryValue); return_value->Set(L"properties", properties); diff --git a/chrome/test/pyautolib/pyauto.py b/chrome/test/pyautolib/pyauto.py index 72cd720..661b7c3 100644 --- a/chrome/test/pyautolib/pyauto.py +++ b/chrome/test/pyautolib/pyauto.py @@ -497,7 +497,8 @@ class PyUITest(pyautolib.PyUITestBase, unittest.TestCase): u'HelperProcessExecutableName': u'Chromium Helper', u'HelperProcessExecutablePath': u'Chromium Helper.app/Contents/' 'MacOS/Chromium Helper', - u'command_line_string': "COMMAND_LINE_STRING --WITH-FLAGS"}, + u'command_line_string': "COMMAND_LINE_STRING --WITH-FLAGS", + u'branding': 'Chromium',} # The order of the windows and tabs listed here will be the same as # what shows up on screen. u'windows': [ { u'index': 0, |