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

Side by Side Diff: tools/telemetry/telemetry/inspector_page.py

Issue 12294002: Revert 182991 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 7 years, 10 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
OLDNEW
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 import json 4 import json
5 import logging 5 import logging
6 6
7 from telemetry import util 7 from telemetry import util
8 8
9 class InspectorPage(object): 9 class InspectorPage(object):
10 def __init__(self, inspector_backend): 10 def __init__(self, inspector_backend):
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
86 """Returns the value of the cookie by the given |name|.""" 86 """Returns the value of the cookie by the given |name|."""
87 request = { 87 request = {
88 'method': 'Page.getCookies' 88 'method': 'Page.getCookies'
89 } 89 }
90 res = self._inspector_backend.SyncRequest(request, timeout) 90 res = self._inspector_backend.SyncRequest(request, timeout)
91 cookies = res['result']['cookies'] 91 cookies = res['result']['cookies']
92 for cookie in cookies: 92 for cookie in cookies:
93 if cookie['name'] == name: 93 if cookie['name'] == name:
94 return cookie['value'] 94 return cookie['value']
95 return None 95 return None
OLDNEW
« no previous file with comments | « tools/telemetry/telemetry/inspector_console_unittest.py ('k') | tools/telemetry/telemetry/inspector_page_unittest.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698