OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include <string> | 5 #include <string> |
6 | 6 |
7 #include "base/string16.h" | 7 #include "base/strings/string16.h" |
8 #include "base/strings/utf_string_conversions.h" | 8 #include "base/strings/utf_string_conversions.h" |
9 #include "chrome/common/automation_constants.h" | 9 #include "chrome/common/automation_constants.h" |
10 #include "chrome/test/webdriver/keycode_text_conversion.h" | 10 #include "chrome/test/webdriver/keycode_text_conversion.h" |
11 #include "chrome/test/webdriver/webdriver_test_util.h" | 11 #include "chrome/test/webdriver/webdriver_test_util.h" |
12 #include "testing/gtest/include/gtest/gtest.h" | 12 #include "testing/gtest/include/gtest/gtest.h" |
13 #include "ui/base/keycodes/keyboard_codes.h" | 13 #include "ui/base/keycodes/keyboard_codes.h" |
14 | 14 |
15 using automation::kShiftKeyMask; | 15 using automation::kShiftKeyMask; |
16 using webdriver::ConvertKeyCodeToText; | 16 using webdriver::ConvertKeyCodeToText; |
17 using webdriver::ConvertCharToKeyCode; | 17 using webdriver::ConvertCharToKeyCode; |
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
110 CheckCharToKeyCode(';', ui::VKEY_Q, 0); | 110 CheckCharToKeyCode(';', ui::VKEY_Q, 0); |
111 EXPECT_EQ(";", ConvertKeyCodeToText(ui::VKEY_Q, 0)); | 111 EXPECT_EQ(";", ConvertKeyCodeToText(ui::VKEY_Q, 0)); |
112 #elif defined(OS_MACOSX) | 112 #elif defined(OS_MACOSX) |
113 ASSERT_TRUE(SwitchKeyboardLayout("com.apple.keylayout.German")); | 113 ASSERT_TRUE(SwitchKeyboardLayout("com.apple.keylayout.German")); |
114 CheckCharToKeyCode('z', ui::VKEY_Y, 0); | 114 CheckCharToKeyCode('z', ui::VKEY_Y, 0); |
115 EXPECT_EQ("z", ConvertKeyCodeToText(ui::VKEY_Y, 0)); | 115 EXPECT_EQ("z", ConvertKeyCodeToText(ui::VKEY_Y, 0)); |
116 #endif | 116 #endif |
117 } | 117 } |
118 | 118 |
119 } // namespace webdriver | 119 } // namespace webdriver |
OLD | NEW |