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

Unified Diff: client/site_tests/factory_SelectKeyboard/factory_SelectKeyboard.py

Issue 6679050: Use keyboard_layout instead of initial_locale (Closed) Base URL: ssh://git@gitrw.chromium.org:9222/autotest.git@0.11.241.B
Patch Set: typos Created 9 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
Index: client/site_tests/factory_SelectKeyboard/factory_SelectKeyboard.py
diff --git a/client/site_tests/factory_SelectKeyboard/factory_SelectKeyboard.py b/client/site_tests/factory_SelectKeyboard/factory_SelectKeyboard.py
index 7245a90b4c78a22723161cca0cd707b6583ec572..ac6d5fc45078f2588d60c6ef0309dfa32705bdab 100644
--- a/client/site_tests/factory_SelectKeyboard/factory_SelectKeyboard.py
+++ b/client/site_tests/factory_SelectKeyboard/factory_SelectKeyboard.py
@@ -22,20 +22,23 @@ from autotest_lib.client.common_lib import error
# Mapping between menu choice and KB.
kb_map = {
- '1': 'en-US',
- '2': 'en-GB',
- 'q': None,
+ '1': ('United Stattes', 'en-US', 'xkb:us::eng'),
yongjaek 2011/03/14 23:08:33 Stattes -> States ;-)
+ '2': ('United Kingdom', 'en-GB', 'xkb:gb:extd:eng'),
+ 'q': ('None', None, None)
}
# Message to display.
-msg = ('Choose a keyboard:\n' +
- "".join([ '%s) %s\n' % (i, kb_map[i]) for i in sorted(kb_map)]))
+msg = ('Choose a keyboard:\n' +
+ "".join([ '%s) %s - %s\n' % (i, kb_map[i][0], kb_map[i][1])
+ for i in sorted(kb_map)]))
class factory_SelectKeyboard(test.test):
version = 1
def write_kb(self, kb):
- cmd = 'vpd -s "initial_locale"="%s"' % kb
+ cmd = 'vpd -i RO_VPD -s "initial_locale"="%s"' % kb[1]
+ utils.system_output(cmd)
+ cmd = 'vpd -i RO_VPD -s "keyboard_layout"="%s"' % kb[2]
utils.system_output(cmd)
def key_release_callback(self, widget, event):

Powered by Google App Engine
This is Rietveld 408576698