Index: content/browser/renderer_host/render_widget_host_view_aura_unittest.cc |
diff --git a/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc b/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc |
index 995e81c034aa87c7212a4a2e62e9283b92f1b7db..61b0efcca394852aef6f92d0858dda4ea0a9b84f 100644 |
--- a/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc |
+++ b/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc |
@@ -4216,4 +4216,21 @@ TEST_F(InputMethodResultAuraTest, InsertText) { |
} |
} |
+// This test makes a specific child frame's view active and then forces the |
+// tab's view end the current IME composition session by sending out an IME |
+// IPC to confirm composition. The test then verifies that the message is sent |
+// to the active widget's process. |
+TEST_F(InputMethodResultAuraTest, FinishImeCompositionSession) { |
+ base::Closure ime_finish_session_call = |
+ base::Bind(&RenderWidgetHostViewAura::FinishImeCompositionSession, |
+ base::Unretained(tab_view())); |
+ for (auto index : active_view_sequence_) { |
+ ActivateViewForTextInputManager(views_[index], ui::TEXT_INPUT_TYPE_TEXT); |
+ SetHasCompositionTextToTrue(); |
+ EXPECT_TRUE(!!RunAndReturnIPCSent(ime_finish_session_call, |
+ processes_[index], |
+ InputMsg_ImeConfirmComposition::ID)); |
+ } |
+} |
+ |
} // namespace content |