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

Unified Diff: media/crypto/aes_decryptor_unittest.cc

Issue 17408005: Refactored DecoderBuffer to use unix_hacker_style naming. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@localrefactor
Patch Set: Created 7 years, 5 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 | « media/crypto/aes_decryptor.cc ('k') | media/filters/audio_file_reader_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/crypto/aes_decryptor_unittest.cc
diff --git a/media/crypto/aes_decryptor_unittest.cc b/media/crypto/aes_decryptor_unittest.cc
index 82b9243d932c83aaf1fb547f569a75210cf886d7..85f864ac1b61bc8499082875e25a8217fa688cf2 100644
--- a/media/crypto/aes_decryptor_unittest.cc
+++ b/media/crypto/aes_decryptor_unittest.cc
@@ -200,7 +200,7 @@ static scoped_refptr<DecoderBuffer> CreateWebMEncryptedBuffer(
data_offset += kWebMIvSize;
}
- encrypted_buffer->SetDecryptConfig(
+ encrypted_buffer->set_decrypt_config(
scoped_ptr<DecryptConfig>(new DecryptConfig(
std::string(reinterpret_cast<const char*>(key_id), key_id_size),
counter_block_str,
@@ -218,7 +218,7 @@ static scoped_refptr<DecoderBuffer> CreateSubsampleEncryptedBuffer(
scoped_refptr<DecoderBuffer> encrypted_buffer =
DecoderBuffer::CopyFrom(data, data_size);
CHECK(encrypted_buffer.get());
- encrypted_buffer->SetDecryptConfig(
+ encrypted_buffer->set_decrypt_config(
scoped_ptr<DecryptConfig>(new DecryptConfig(
std::string(reinterpret_cast<const char*>(key_id), key_id_size),
std::string(reinterpret_cast<const char*>(iv), iv_size),
@@ -274,8 +274,8 @@ class AesDecryptorTest : public testing::Test {
decryptor_.Decrypt(Decryptor::kVideo, encrypted, decrypt_cb_);
ASSERT_TRUE(decrypted.get());
- ASSERT_EQ(plain_text_size, decrypted->GetDataSize());
- EXPECT_EQ(0, memcmp(plain_text, decrypted->GetData(), plain_text_size));
+ ASSERT_EQ(plain_text_size, decrypted->data_size());
+ EXPECT_EQ(0, memcmp(plain_text, decrypted->data(), plain_text_size));
}
void DecryptAndExpectDataMismatch(
@@ -287,8 +287,8 @@ class AesDecryptorTest : public testing::Test {
decryptor_.Decrypt(Decryptor::kVideo, encrypted, decrypt_cb_);
ASSERT_TRUE(decrypted.get());
- ASSERT_EQ(plain_text_size, decrypted->GetDataSize());
- EXPECT_NE(0, memcmp(plain_text, decrypted->GetData(), plain_text_size));
+ ASSERT_EQ(plain_text_size, decrypted->data_size());
+ EXPECT_NE(0, memcmp(plain_text, decrypted->data(), plain_text_size));
}
void DecryptAndExpectSizeDataMismatch(
@@ -300,8 +300,8 @@ class AesDecryptorTest : public testing::Test {
decryptor_.Decrypt(Decryptor::kVideo, encrypted, decrypt_cb_);
ASSERT_TRUE(decrypted.get());
- EXPECT_NE(plain_text_size, decrypted->GetDataSize());
- EXPECT_NE(0, memcmp(plain_text, decrypted->GetData(), plain_text_size));
+ EXPECT_NE(plain_text_size, decrypted->data_size());
+ EXPECT_NE(0, memcmp(plain_text, decrypted->data(), plain_text_size));
}
void DecryptAndExpectToFail(const scoped_refptr<DecoderBuffer>& encrypted) {
« no previous file with comments | « media/crypto/aes_decryptor.cc ('k') | media/filters/audio_file_reader_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698