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

Unified Diff: chrome/browser/renderer_host/text_input_client_mac_unittest.mm

Issue 7019033: Revert 86246 - Fix assertion failure in range.mm while examining system dictionary popup. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 7 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
« no previous file with comments | « no previous file | chrome/browser/renderer_host/text_input_client_message_filter.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/renderer_host/text_input_client_mac_unittest.mm
===================================================================
--- chrome/browser/renderer_host/text_input_client_mac_unittest.mm (revision 86247)
+++ chrome/browser/renderer_host/text_input_client_mac_unittest.mm (working copy)
@@ -7,7 +7,6 @@
#include "base/bind.h"
#include "base/message_loop.h"
#include "base/threading/thread.h"
-#include "chrome/browser/renderer_host/text_input_client_message_filter.h"
#include "chrome/common/text_input_client_messages.h"
#include "chrome/test/testing_profile.h"
#include "content/browser/renderer_host/mock_render_process_host.h"
@@ -107,32 +106,6 @@
EXPECT_EQ(NSNotFound, index);
}
-TEST_F(TextInputClientMacTest, NotFoundCharacterIndex) {
- ScopedTestingThread thread(this);
- const NSUInteger kPreviousValue = 42;
- const size_t kNotFoundValue = static_cast<size_t>(-1);
-
- // Set an arbitrary value to ensure the index is not |NSNotFound|.
- PostTask(base::Bind(&TextInputClientMac::SetCharacterIndexAndSignal,
- base::Unretained(service()), kPreviousValue));
-
- scoped_refptr<TextInputClientMessageFilter> filter(
- new TextInputClientMessageFilter(widget()->process()->id()));
- scoped_ptr<IPC::Message> message(
- new TextInputClientReplyMsg_GotCharacterIndexForPoint(
- widget()->routing_id(), kNotFoundValue));
- bool message_ok = true;
- PostTask(base::Bind(&TextInputClientMessageFilter::OnMessageReceived,
- filter.get(), *message, &message_ok));
-
- NSUInteger index = service()->GetCharacterIndexAtPoint(
- widget(), gfx::Point(2, 2));
- EXPECT_EQ(1U, ipc_sink().message_count());
- EXPECT_TRUE(ipc_sink().GetUniqueMessageMatching(
- TextInputClientMsg_CharacterIndexForPoint::ID));
- EXPECT_EQ(NSNotFound, index);
-}
-
TEST_F(TextInputClientMacTest, GetRectForRange) {
ScopedTestingThread thread(this);
const NSRect kSuccessValue = NSMakeRect(42, 43, 44, 45);
« no previous file with comments | « no previous file | chrome/browser/renderer_host/text_input_client_message_filter.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698