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

Unified Diff: media/cdm/aes_decryptor_unittest.cc

Issue 813683005: Add |legacy_destination_url| back to SessionMessage for EME (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: changes Created 5 years, 11 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: media/cdm/aes_decryptor_unittest.cc
diff --git a/media/cdm/aes_decryptor_unittest.cc b/media/cdm/aes_decryptor_unittest.cc
index cfa97b1b847fbcb3b37a3ecc91c880819d53e795..a630b02d13194cdfa1f1b46f3ed14f9c109f6cbe 100644
--- a/media/cdm/aes_decryptor_unittest.cc
+++ b/media/cdm/aes_decryptor_unittest.cc
@@ -282,7 +282,8 @@ class AesDecryptorTest : public testing::Test {
// Creates a new session using |key_id|. Returns the session ID.
std::string CreateSession(const std::vector<uint8>& key_id) {
DCHECK(!key_id.empty());
- EXPECT_CALL(*this, OnSessionMessage(IsNotEmpty(), _, IsJSONDictionary()));
+ EXPECT_CALL(*this, OnSessionMessage(IsNotEmpty(), _, IsJSONDictionary(),
+ GURL::EmptyGURL()));
decryptor_.CreateSessionAndGenerateRequest(
MediaKeys::TEMPORARY_SESSION, std::string(), &key_id[0], key_id.size(),
CreateSessionPromise(RESOLVED));
@@ -403,10 +404,11 @@ class AesDecryptorTest : public testing::Test {
}
}
- MOCK_METHOD3(OnSessionMessage,
+ MOCK_METHOD4(OnSessionMessage,
void(const std::string& web_session_id,
MediaKeys::MessageType message_type,
- const std::vector<uint8>& message));
+ const std::vector<uint8>& message,
+ const GURL& legacy_destination_url));
MOCK_METHOD1(OnSessionClosed, void(const std::string& web_session_id));
AesDecryptor decryptor_;
@@ -425,24 +427,28 @@ class AesDecryptorTest : public testing::Test {
};
TEST_F(AesDecryptorTest, CreateSessionWithNullInitData) {
- EXPECT_CALL(*this, OnSessionMessage(IsNotEmpty(), _, IsEmpty()));
+ EXPECT_CALL(*this,
+ OnSessionMessage(IsNotEmpty(), _, IsEmpty(), GURL::EmptyGURL()));
decryptor_.CreateSessionAndGenerateRequest(MediaKeys::TEMPORARY_SESSION,
std::string(), NULL, 0,
CreateSessionPromise(RESOLVED));
}
TEST_F(AesDecryptorTest, MultipleCreateSession) {
- EXPECT_CALL(*this, OnSessionMessage(IsNotEmpty(), _, IsEmpty()));
+ EXPECT_CALL(*this,
+ OnSessionMessage(IsNotEmpty(), _, IsEmpty(), GURL::EmptyGURL()));
decryptor_.CreateSessionAndGenerateRequest(MediaKeys::TEMPORARY_SESSION,
std::string(), NULL, 0,
CreateSessionPromise(RESOLVED));
- EXPECT_CALL(*this, OnSessionMessage(IsNotEmpty(), _, IsEmpty()));
+ EXPECT_CALL(*this,
+ OnSessionMessage(IsNotEmpty(), _, IsEmpty(), GURL::EmptyGURL()));
decryptor_.CreateSessionAndGenerateRequest(MediaKeys::TEMPORARY_SESSION,
std::string(), NULL, 0,
CreateSessionPromise(RESOLVED));
- EXPECT_CALL(*this, OnSessionMessage(IsNotEmpty(), _, IsEmpty()));
+ EXPECT_CALL(*this,
+ OnSessionMessage(IsNotEmpty(), _, IsEmpty(), GURL::EmptyGURL()));
decryptor_.CreateSessionAndGenerateRequest(MediaKeys::TEMPORARY_SESSION,
std::string(), NULL, 0,
CreateSessionPromise(RESOLVED));

Powered by Google App Engine
This is Rietveld 408576698