Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(413)

Side by Side Diff: chrome/test/webdriver/automation.h

Issue 6705004: Return the full cookie details in TestingAutomationProvider and pass around (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: ... Created 9 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/test/webdriver/WEBDRIVER_TESTS ('k') | chrome/test/webdriver/automation.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_TEST_WEBDRIVER_AUTOMATION_H_ 5 #ifndef CHROME_TEST_WEBDRIVER_AUTOMATION_H_
6 #define CHROME_TEST_WEBDRIVER_AUTOMATION_H_ 6 #define CHROME_TEST_WEBDRIVER_AUTOMATION_H_
7 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
11 11
12 #include "base/task.h" 12 #include "base/task.h"
13 #include "base/ref_counted.h" 13 #include "base/ref_counted.h"
14 #include "base/scoped_ptr.h" 14 #include "base/scoped_ptr.h"
15 #include "chrome/common/automation_constants.h" 15 #include "chrome/common/automation_constants.h"
16 #include "ui/base/keycodes/keyboard_codes.h" 16 #include "ui/base/keycodes/keyboard_codes.h"
17 17
18 class AutomationProxy; 18 class AutomationProxy;
19 class DictionaryValue; 19 class DictionaryValue;
20 class FilePath; 20 class FilePath;
21 class GURL; 21 class GURL;
22 class ListValue;
22 class ProxyLauncher; 23 class ProxyLauncher;
23 struct WebKeyEvent; 24 struct WebKeyEvent;
24 25
25 namespace gfx { 26 namespace gfx {
26 class Point; 27 class Point;
27 } 28 }
28 29
29 namespace webdriver { 30 namespace webdriver {
30 31
31 class FramePath; 32 class FramePath;
(...skipping 27 matching lines...) Expand all
59 // been processed by the web page. 60 // been processed by the web page.
60 void SendWebKeyEvent(int tab_id, const WebKeyEvent& key_event, bool* success); 61 void SendWebKeyEvent(int tab_id, const WebKeyEvent& key_event, bool* success);
61 62
62 void NavigateToURL(int tab_id, const std::string& url, bool* success); 63 void NavigateToURL(int tab_id, const std::string& url, bool* success);
63 void GoForward(int tab_id, bool* success); 64 void GoForward(int tab_id, bool* success);
64 void GoBack(int tab_id, bool* success); 65 void GoBack(int tab_id, bool* success);
65 void Reload(int tab_id, bool* success); 66 void Reload(int tab_id, bool* success);
66 void GetURL(int tab_id, std::string* url, bool* success); 67 void GetURL(int tab_id, std::string* url, bool* success);
67 void GetGURL(int tab_id, GURL* gurl, bool* success); 68 void GetGURL(int tab_id, GURL* gurl, bool* success);
68 void GetTabTitle(int tab_id, std::string* tab_title, bool* success); 69 void GetTabTitle(int tab_id, std::string* tab_title, bool* success);
69 void GetCookies( 70
71 void GetCookies(const std::string& url, ListValue** cookies, bool* success);
72 void GetCookiesDeprecated(
70 int tab_id, const GURL& gurl, std::string* cookies, bool* success); 73 int tab_id, const GURL& gurl, std::string* cookies, bool* success);
71 void DeleteCookie(int tab_id, 74 void DeleteCookie(const std::string& url,
72 const GURL& gurl,
73 const std::string& cookie_name, 75 const std::string& cookie_name,
74 bool* success); 76 bool* success);
77 void DeleteCookieDeprecated(int tab_id,
78 const GURL& gurl,
79 const std::string& cookie_name,
80 bool* success);
75 void SetCookie( 81 void SetCookie(
82 const std::string& url, DictionaryValue* cookie_dict, bool* success);
83 void SetCookieDeprecated(
76 int tab_id, const GURL& gurl, const std::string& cookie, bool* success); 84 int tab_id, const GURL& gurl, const std::string& cookie, bool* success);
85
77 void MouseMove(int tab_id, const gfx::Point& p, bool* success); 86 void MouseMove(int tab_id, const gfx::Point& p, bool* success);
78 void MouseClick(int tab_id, 87 void MouseClick(int tab_id,
79 const gfx::Point& p, 88 const gfx::Point& p,
80 automation::MouseButton button, 89 automation::MouseButton button,
81 bool* success); 90 bool* success);
82 void MouseDrag(int tab_id, 91 void MouseDrag(int tab_id,
83 const gfx::Point& start, 92 const gfx::Point& start,
84 const gfx::Point& end, 93 const gfx::Point& end,
85 bool* success); 94 bool* success);
86 95
87 // Get persistent IDs for all the tabs currently open. These IDs can be used 96 // Get persistent IDs for all the tabs currently open. These IDs can be used
88 // to identify the tab as long as the tab exists. 97 // to identify the tab as long as the tab exists.
89 void GetTabIds(std::vector<int>* tab_ids, bool* success); 98 void GetTabIds(std::vector<int>* tab_ids, bool* success);
90 99
91 // Check if the given tab exists currently. 100 // Check if the given tab exists currently.
92 void DoesTabExist(int tab_id, bool* does_exist, bool* success); 101 void DoesTabExist(int tab_id, bool* does_exist, bool* success);
93 102
94 void CloseTab(int tab_id, bool* success); 103 void CloseTab(int tab_id, bool* success);
95 104
96 // Gets the version of the runing browser. 105 // Gets the version of the runing browser.
97 void GetVersion(std::string* version); 106 void GetBrowserVersion(std::string* version);
98 107
99 // Waits for all tabs to stop loading. 108 // Waits for all tabs to stop loading.
100 void WaitForAllTabsToStopLoading(bool* success); 109 void WaitForAllTabsToStopLoading(bool* success);
101 110
102 private: 111 private:
103 AutomationProxy* automation() const; 112 AutomationProxy* automation() const;
104 bool GetIndicesForTab(int tab_id, int* browser_index, int* tab_index); 113 bool GetIndicesForTab(int tab_id, int* browser_index, int* tab_index);
105 114
106 scoped_ptr<ProxyLauncher> launcher_; 115 scoped_ptr<ProxyLauncher> launcher_;
107 116
108 DISALLOW_COPY_AND_ASSIGN(Automation); 117 DISALLOW_COPY_AND_ASSIGN(Automation);
109 }; 118 };
110 119
111 } // namespace webdriver 120 } // namespace webdriver
112 121
113 DISABLE_RUNNABLE_METHOD_REFCOUNT(webdriver::Automation); 122 DISABLE_RUNNABLE_METHOD_REFCOUNT(webdriver::Automation);
114 123
115 #endif // CHROME_TEST_WEBDRIVER_AUTOMATION_H_ 124 #endif // CHROME_TEST_WEBDRIVER_AUTOMATION_H_
OLDNEW
« no previous file with comments | « chrome/test/webdriver/WEBDRIVER_TESTS ('k') | chrome/test/webdriver/automation.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698