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

Side by Side Diff: ui/base/ime/input_method_ibus_unittest.cc

Issue 10824064: Use EXPECT_FALSE instead of EXPECT_EQ to avoid compiler error (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 8 years, 4 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 unified diff | Download patch
« no previous file with comments | « ui/aura/window_unittest.cc ('k') | ui/views/view_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 <cstring> 5 #include <cstring>
6 6
7 #include "base/i18n/char_iterator.h" 7 #include "base/i18n/char_iterator.h"
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "base/utf_string_conversions.h" 9 #include "base/utf_string_conversions.h"
10 #include "chromeos/dbus/dbus_thread_manager.h" 10 #include "chromeos/dbus/dbus_thread_manager.h"
(...skipping 273 matching lines...) Expand 10 before | Expand all | Expand 10 after
284 input_type_ = TEXT_INPUT_TYPE_TEXT; 284 input_type_ = TEXT_INPUT_TYPE_TEXT;
285 ime_->OnTextInputTypeChanged(this); 285 ime_->OnTextInputTypeChanged(this);
286 EXPECT_EQ(TEXT_INPUT_TYPE_TEXT, ime_->GetTextInputType()); 286 EXPECT_EQ(TEXT_INPUT_TYPE_TEXT, ime_->GetTextInputType());
287 } 287 }
288 288
289 TEST_F(InputMethodIBusTest, CanComposeInline) { 289 TEST_F(InputMethodIBusTest, CanComposeInline) {
290 ime_->Init(true); 290 ime_->Init(true);
291 EXPECT_EQ(true, ime_->CanComposeInline()); 291 EXPECT_EQ(true, ime_->CanComposeInline());
292 can_compose_inline_ = false; 292 can_compose_inline_ = false;
293 ime_->OnTextInputTypeChanged(this); 293 ime_->OnTextInputTypeChanged(this);
294 EXPECT_EQ(false, ime_->CanComposeInline()); 294 EXPECT_FALSE(ime_->CanComposeInline());
295 } 295 }
296 296
297 TEST_F(InputMethodIBusTest, GetTextInputClient) { 297 TEST_F(InputMethodIBusTest, GetTextInputClient) {
298 ime_->Init(true); 298 ime_->Init(true);
299 EXPECT_EQ(this, ime_->GetTextInputClient()); 299 EXPECT_EQ(this, ime_->GetTextInputClient());
300 ime_->SetFocusedTextInputClient(NULL); 300 ime_->SetFocusedTextInputClient(NULL);
301 EXPECT_EQ(NULL, ime_->GetTextInputClient()); 301 EXPECT_EQ(NULL, ime_->GetTextInputClient());
302 } 302 }
303 303
304 TEST_F(InputMethodIBusTest, GetInputTextType_WithoutFocusedClient) { 304 TEST_F(InputMethodIBusTest, GetInputTextType_WithoutFocusedClient) {
(...skipping 466 matching lines...) Expand 10 before | Expand all | Expand 10 after
771 composition_text.underlines[0].start_offset); 771 composition_text.underlines[0].start_offset);
772 EXPECT_EQ(GetOffsetInUTF16(kSampleText, selection.end_index), 772 EXPECT_EQ(GetOffsetInUTF16(kSampleText, selection.end_index),
773 composition_text.underlines[0].end_offset); 773 composition_text.underlines[0].end_offset);
774 EXPECT_EQ(SK_ColorBLACK, composition_text.underlines[0].color); 774 EXPECT_EQ(SK_ColorBLACK, composition_text.underlines[0].color);
775 EXPECT_TRUE(composition_text.underlines[0].thick); 775 EXPECT_TRUE(composition_text.underlines[0].thick);
776 } 776 }
777 777
778 // TODO(nona): Write more tests, especially for key event functions. 778 // TODO(nona): Write more tests, especially for key event functions.
779 779
780 } // namespace ui 780 } // namespace ui
OLDNEW
« no previous file with comments | « ui/aura/window_unittest.cc ('k') | ui/views/view_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698