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): |