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

Unified Diff: chrome/test/data/webui/md_bookmarks/edit_dialog_test.js

Issue 2769103002: MD Bookmarks: Save and close bookmark edit dialog on 'enter' key press. (Closed)
Patch Set: Closure Created 3 years, 9 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/browser/resources/md_bookmarks/edit_dialog.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_bookmarks/edit_dialog_test.js
diff --git a/chrome/test/data/webui/md_bookmarks/edit_dialog_test.js b/chrome/test/data/webui/md_bookmarks/edit_dialog_test.js
index 5bc4269e2644db0b0473c9abcf9aa0d27cd83823..3eb9a2d7dca14b96b60080872a59e8007274b7d8 100644
--- a/chrome/test/data/webui/md_bookmarks/edit_dialog_test.js
+++ b/chrome/test/data/webui/md_bookmarks/edit_dialog_test.js
@@ -55,4 +55,12 @@ suite('<bookmarks-edit-dialog>', function() {
assertEquals(undefined, lastUpdate.edit.url);
assertEquals('Awesome websites', lastUpdate.edit.title);
});
+
+ test('pressing enter saves and closes dialog', function() {
+ var item = createItem('1', {url: 'http://www.example.com'});
+ dialog.showEditDialog(item);
+
+ MockInteractions.pressEnter(dialog.$.url);
+ assertFalse(dialog.$.dialog.open);
+ });
});
« no previous file with comments | « chrome/browser/resources/md_bookmarks/edit_dialog.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698