@@ -57,21 +57,26 @@ def get_cookie_value(self, name):
5757 def get_cookie (self , name ):
5858 """Returns a cookie object found with ``name``.
5959
60- The cookie object contains details about the cookie.
61- Attributes available in the object are documented in the table below.
60+ If no cookie is found with ``name``, keyword fails. The cookie object
61+ contains details about the cookie. Attributes available in the object
62+ are documented in the table below.
6263 | = Attribute = | = Explanation = |
6364 | domain | Specifies hosts to which the cookie will be sent |
6465 | expiry | The maximum lifetime of the cookie as EPOCH |
6566 | httpOnly | HttpOnly cookie cannot be accessed by client-side APIs |
6667 | name | The name of a cookie |
67- | path | Indicates a URL path, usually / |
68+ | path | Indicates a URL path, example / |
6869 | secure | Cookie will be send only by using secure connection |
6970 | value | Value of the cookie |
7071 | full_info | All the above attributes joined as string |
7172
72- If no cookie is found with ``name``, this keyword fails.
73-
7473 New in SeleniumLibrary 3.0
74+
75+ Example:
76+ | Add Cookie | foo | bar |
77+ | ${cookie} = | Get Cookie | foo |
78+ | Should Be Equal | ${cookie.value} | foo |
79+ | Should Be Equal | ${cookie.name} | bar |
7580 """
7681 cookie = self .browser .get_cookie (name )
7782 if cookie :
0 commit comments