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

Unified Diff: chrome/test/data/webui/settings/rtl_tests.js

Issue 1700273003: MD Settings: make <paper-drawer-panel> flip in RTL (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: michaelpg@ review Created 4 years, 10 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/settings/cr_settings_browsertest.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/settings/rtl_tests.js
diff --git a/chrome/test/data/webui/settings/rtl_tests.js b/chrome/test/data/webui/settings/rtl_tests.js
new file mode 100644
index 0000000000000000000000000000000000000000..2153f7afa7b0807cd2638aa36ed27a75df7ecf5e
--- /dev/null
+++ b/chrome/test/data/webui/settings/rtl_tests.js
@@ -0,0 +1,30 @@
+// 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.
+
+cr.define('settings_rtl_tests', function() {
+ /** @implements {settings.DirectionDelegate} */
+ function TestDirectionDelegate(isRtl) {
+ /** @override */
+ this.isRtl = function() { return isRtl; };
+ }
+
+ function registerDrawerPanelTests() {
+ suite('settings drawer panel RTL tests', function() {
+ test('test i18n processing flips drawer panel', function() {
+ var ui = document.createElement('settings-ui');
+ assertFalse(ui.$.panel.rightDrawer);
+
+ ui.directionDelegate = new TestDirectionDelegate(true /* isRtl */);
+ assertTrue(ui.$.panel.rightDrawer);
+
+ ui.directionDelegate = new TestDirectionDelegate(false /* isRtl */);
+ assertFalse(ui.$.panel.rightDrawer);
+ });
+ });
+ }
+
+ return {
+ registerDrawerPanelTests: registerDrawerPanelTests,
+ };
+});
« no previous file with comments | « chrome/test/data/webui/settings/cr_settings_browsertest.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698