Index: content/browser/presentation/presentation_service_impl_unittest.cc |
diff --git a/content/browser/presentation/presentation_service_impl_unittest.cc b/content/browser/presentation/presentation_service_impl_unittest.cc |
index 8bfa5fc3934f6bc991eb98c1e15ff53e57370e00..5f8223666e023ac43fc1eef2499ffb340793865f 100644 |
--- a/content/browser/presentation/presentation_service_impl_unittest.cc |
+++ b/content/browser/presentation/presentation_service_impl_unittest.cc |
@@ -107,6 +107,10 @@ class MockPresentationServiceDelegate : public PresentationServiceDelegate { |
void(int render_process_id, |
int render_frame_id, |
const std::string& presentation_id)); |
+ MOCK_METHOD3(TerminateSession, |
+ void(int render_process_id, |
+ int render_frame_id, |
+ const std::string& presentation_id)); |
MOCK_METHOD4(ListenForSessionMessages, |
void(int render_process_id, |
int render_frame_id, |
@@ -575,6 +579,14 @@ TEST_F(PresentationServiceImplTest, CloseSession) { |
run_loop.Run(); |
} |
+TEST_F(PresentationServiceImplTest, TerminateSession) { |
+ service_ptr_->TerminateSession(kPresentationUrl, kPresentationId); |
+ base::RunLoop run_loop; |
+ EXPECT_CALL(mock_delegate_, TerminateSession(_, _, Eq(kPresentationId))) |
+ .WillOnce(InvokeWithoutArgs(&run_loop, &base::RunLoop::Quit)); |
+ run_loop.Run(); |
+} |
+ |
TEST_F(PresentationServiceImplTest, ListenForSessionMessagesPassed) { |
std::string text_msg("123"); |
std::vector<uint8_t> binary_data(3, '\1'); |