Chromium Code Reviews| Index: chrome/test/data/webui/profile_window_browsertest.js |
| diff --git a/chrome/test/data/webui/profile_window_browsertest.js b/chrome/test/data/webui/profile_window_browsertest.js |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..01c06d32df113a37b433f5dde24415a4ec9a588e |
| --- /dev/null |
| +++ b/chrome/test/data/webui/profile_window_browsertest.js |
| @@ -0,0 +1,15 @@ |
| +// Copyright 2016 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +function testNoPodFocuesd() { |
|
Dan Beam
2016/03/30 17:53:29
Focused
lwchkg
2016/03/31 14:48:16
Done.
|
| + expectEquals(null, document.querySelector('.pod.focused'), |
| + "No pod should be focused."); |
| +} |
| + |
| +function testPodFocuesd(profile_path) { |
|
Dan Beam
2016/03/30 17:53:28
jsVarsLikeThis (i.e. profile_path -> profilePath)
Dan Beam
2016/03/30 17:53:29
Focused
lwchkg
2016/03/31 14:48:16
Done.
lwchkg
2016/03/31 14:48:16
Done.
|
| + var pods = document.querySelectorAll('.pod.focused'); |
| + assertEquals(1, pods.length, "Exactly one pod should be focused."); |
| + expectEquals(profile_path, pods[0].user.profilePath, |
| + "A wrong pod is focused."); |
| +} |