1 # Copyright 2013 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file.
5 from telemetry
.core
import exceptions
6 from telemetry
.internal
.backends
.chrome
import oobe
7 from telemetry
.internal
.backends
.chrome_inspector
import inspector_backend_list
10 class MiscWebContentsBackend(inspector_backend_list
.InspectorBackendList
):
11 """A dynamic sequence of web contents not related to tabs and extensions.
13 Provides acccess to chrome://oobe/login page.
16 def __init__(self
, browser_backend
):
17 super(MiscWebContentsBackend
, self
).__init
__(browser_backend
)
20 def oobe_exists(self
):
21 """Lightweight property to determine if the oobe webui is visible."""
23 return bool(len(self
))
24 except exceptions
.Error
:
32 def ShouldIncludeContext(self
, context
):
33 return context
.get('url').startswith('chrome://oobe')
35 def CreateWrapper(self
, inspector_backend
):
36 return oobe
.Oobe(inspector_backend
)