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

Unified Diff: ui/keyboard/keyboard_controller_unittest.cc

Issue 13925020: keyboard: Add a test suite for the tests, and initialize all the UI things properly. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 7 years, 8 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: ui/keyboard/keyboard_controller_unittest.cc
diff --git a/ui/keyboard/keyboard_controller_unittest.cc b/ui/keyboard/keyboard_controller_unittest.cc
index 8c9b01092bf7a59344c1ef7e792f037fa9ea2534..f21737b1552d4e9094950813ed71994a7858a8ac 100644
--- a/ui/keyboard/keyboard_controller_unittest.cc
+++ b/ui/keyboard/keyboard_controller_unittest.cc
@@ -12,7 +12,7 @@
#include "ui/aura/test/test_window_delegate.h"
#include "ui/aura/window.h"
#include "ui/base/ime/input_method.h"
-#include "ui/base/ime/mock_input_method.h"
+#include "ui/base/ime/input_method_factory.h"
#include "ui/base/ime/text_input_client.h"
#include "ui/compositor/layer_type.h"
#include "ui/gfx/rect.h"
@@ -57,6 +57,7 @@ class KeyboardControllerTest : public testing::Test {
virtual void SetUp() OVERRIDE {
aura_test_helper_.reset(new aura::test::AuraTestHelper(&message_loop_));
aura_test_helper_->SetUp();
+ ui::SetUpInputMethodFacotryForTesting();
bryeung 2013/04/16 14:13:35 typo: Factory
sadrul 2013/04/16 15:24:56 Turns out the function was named Facotry. I have f
focus_controller_.reset(new TestFocusController(root_window()));
}
@@ -79,7 +80,8 @@ class TestKeyboardControllerProxy : public KeyboardControllerProxy {
public:
TestKeyboardControllerProxy()
: window_(new aura::Window(&delegate_)),
- input_method_(new ui::MockInputMethod(NULL)) {
+ input_method_(ui::CreateInputMethod(NULL,
+ gfx::kNullAcceleratedWidget)) {
window_->Init(ui::LAYER_NOT_DRAWN);
window_->set_owned_by_parent(false);
}

Powered by Google App Engine
This is Rietveld 408576698