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.backends import form_based_credentials_backend
8 class FacebookCredentialsBackend(
9 form_based_credentials_backend.FormBasedCredentialsBackend):
10 def IsAlreadyLoggedIn(self, tab):
11 return tab.EvaluateJavaScript(
12 'document.getElementById("fbNotificationsList")!== null || '
13 'document.getElementById("m_home_notice")!== null')
16 def credentials_type(self):
21 return 'http://www.facebook.com/'
24 def login_form_id(self):
28 def login_input_id(self):
32 def password_input_id(self):