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

Unified Diff: chrome/test/data/webui/md_user_manager/import_supervised_user_tests.js

Issue 2024233003: MD User Manager: Refactors existing dialogs in User Manager into <user-manager-dialog> (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@md-user-manager-locked-test
Patch Set: Removed user_manager_dialog gyp target Created 4 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/test/data/webui/md_user_manager/control_bar_tests.js ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/data/webui/md_user_manager/import_supervised_user_tests.js
diff --git a/chrome/test/data/webui/md_user_manager/import_supervised_user_tests.js b/chrome/test/data/webui/md_user_manager/import_supervised_user_tests.js
index 6efec9b7052f9cfb0bd238d4dde7dbcc0b688ed5..de220037e43ce3f89cdd6ee3e32eb78600cec2cc 100644
--- a/chrome/test/data/webui/md_user_manager/import_supervised_user_tests.js
+++ b/chrome/test/data/webui/md_user_manager/import_supervised_user_tests.js
@@ -32,18 +32,18 @@ cr.define('user_manager.import_supervised_user_tests', function() {
test('Dialog does not show if no signed-in user is provided', function() {
// The dialog is initially not visible.
- assertFalse(!!importElement.$$('#backdrop'));
+ assertFalse(importElement.$.dialog.opened);
importElement.show(undefined, []);
Polymer.dom.flush();
// The dialog is still not visible.
- assertFalse(!!importElement.$$('#backdrop'));
+ assertFalse(importElement.$.dialog.opened);
});
test('Dialog shows when there are no supervised users', function() {
// The dialog is initially not visible.
- assertFalse(!!importElement.$$('#backdrop'));
+ assertFalse(importElement.$.dialog.opened);
importElement.show({username: 'username',
profilePath: 'path/to/profile'},
@@ -51,7 +51,7 @@ cr.define('user_manager.import_supervised_user_tests', function() {
Polymer.dom.flush();
// The dialog becomes visible.
- assertLT(0, importElement.$$('#backdrop').offsetHeight);
+ assertTrue(importElement.$.dialog.opened);
// The correct message is displayed.
assertEquals(loadTimeData.getString('noSupervisedUserImportText'),
@@ -69,7 +69,7 @@ cr.define('user_manager.import_supervised_user_tests', function() {
Polymer.dom.flush();
// The dialog is no longer visible.
- assertEquals(0, importElement.$$('#backdrop').offsetHeight);
+ assertFalse(importElement.$.dialog.opened);
});
test('Can import supervised user', function() {
@@ -92,20 +92,20 @@ cr.define('user_manager.import_supervised_user_tests', function() {
event.detail.supervisedUser.name == 'supervised user 2') {
Polymer.dom.flush();
// The dialog is no longer visible.
- assertEquals(0, importElement.$$('#backdrop').offsetHeight);
+ assertFalse(importElement.$.dialog.opened);
resolve();
}
});
// The dialog is initially not visible.
- assertFalse(!!importElement.$$('#backdrop'));
+ assertFalse(importElement.$.dialog.opened);
importElement.show(signedInUser, supervisedUsers);
Polymer.dom.flush();
// The dialog becomes visible.
- assertLT(0, importElement.$$('#backdrop').offsetHeight);
+ assertTrue(importElement.$.dialog.opened);
// The correct message is displayed.
assertEquals(loadTimeData.getString('supervisedUserImportText'),
« no previous file with comments | « chrome/test/data/webui/md_user_manager/control_bar_tests.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698