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

Unified Diff: chrome/browser/media/router/test_helper.h

Issue 1314413005: [Presentation API] 1-UA presentation support + presenter APIs. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 6 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: chrome/browser/media/router/test_helper.h
diff --git a/chrome/browser/media/router/test_helper.h b/chrome/browser/media/router/test_helper.h
index 3179d1511b3c544be3f59e2c1e9f42b2a6641aae..7a8a26de8a30105f45563b8b186ad1c206dcc487 100644
--- a/chrome/browser/media/router/test_helper.h
+++ b/chrome/browser/media/router/test_helper.h
@@ -77,6 +77,11 @@ MATCHER_P(IssueTitleEquals, title, "") {
return arg.title() == title;
}
+MATCHER_P(PresentationConnectionInfoEquals, other, "") {
+ return arg.presentation_url == other.presentation_url &&
+ arg.presentation_id == other.presentation_id;
+}
+
MATCHER_P(StateChageInfoEquals, other, "") {
return arg.state == other.state && arg.close_reason == other.close_reason &&
arg.message == other.message;
@@ -118,6 +123,19 @@ class MockPresentationConnectionStateChangedCallback {
void(const content::PresentationConnectionStateChangeInfo&));
};
+class MockPresentationMessagesCallback {
+ public:
+ MockPresentationMessagesCallback();
+ ~MockPresentationMessagesCallback();
+ void OnMessagesReceived(
+ const ScopedVector<content::PresentationSessionMessage>& messages,
+ bool pass_ownership) {
+ DoOnMessagesReceived(messages[0]->message);
+ }
+ MOCK_METHOD1(DoOnMessagesReceived, void(const std::string&));
+ MOCK_METHOD1(OnMessageSent, void(bool));
+};
+
} // namespace media_router
#endif // CHROME_BROWSER_MEDIA_ROUTER_TEST_HELPER_H_
« no previous file with comments | « chrome/browser/media/router/receiver_presentation_service_delegate_impl.cc ('k') | chrome/browser/media/router/test_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698