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

Unified Diff: media/filters/vp9_raw_bits_reader_unittest.cc

Issue 1258083004: Add a Vp9Parser implementation (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: ReadBool, fix compile warning Created 5 years, 4 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/filters/vp9_raw_bits_reader.cc ('k') | media/media.gyp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/filters/vp9_raw_bits_reader_unittest.cc
diff --git a/media/filters/vp9_raw_bits_reader_unittest.cc b/media/filters/vp9_raw_bits_reader_unittest.cc
index d798f226c21b8fb0f1fa712008b70fa1f8e59b99..999dbe1e989249e8b61124651afb632e4ece903d 100644
--- a/media/filters/vp9_raw_bits_reader_unittest.cc
+++ b/media/filters/vp9_raw_bits_reader_unittest.cc
@@ -7,26 +7,26 @@
namespace media {
-TEST(Vp9RawBitsReaderTest, ReadBit) {
+TEST(Vp9RawBitsReaderTest, ReadBool) {
uint8_t data[] = {0xf1};
Vp9RawBitsReader reader;
reader.Initialize(data, 1);
EXPECT_TRUE(reader.IsValid());
EXPECT_EQ(0u, reader.GetBytesRead());
- EXPECT_EQ(1, reader.ReadBit());
+ EXPECT_TRUE(reader.ReadBool());
EXPECT_EQ(1u, reader.GetBytesRead());
- EXPECT_EQ(1, reader.ReadBit());
- EXPECT_EQ(1, reader.ReadBit());
- EXPECT_EQ(1, reader.ReadBit());
- EXPECT_EQ(0, reader.ReadBit());
- EXPECT_EQ(0, reader.ReadBit());
- EXPECT_EQ(0, reader.ReadBit());
- EXPECT_EQ(1, reader.ReadBit());
+ EXPECT_TRUE(reader.ReadBool());
+ EXPECT_TRUE(reader.ReadBool());
+ EXPECT_TRUE(reader.ReadBool());
+ EXPECT_FALSE(reader.ReadBool());
+ EXPECT_FALSE(reader.ReadBool());
+ EXPECT_FALSE(reader.ReadBool());
+ EXPECT_TRUE(reader.ReadBool());
EXPECT_TRUE(reader.IsValid());
// The return value is undefined.
- ignore_result(reader.ReadBit());
+ ignore_result(reader.ReadBool());
EXPECT_FALSE(reader.IsValid());
EXPECT_EQ(1u, reader.GetBytesRead());
}
« no previous file with comments | « media/filters/vp9_raw_bits_reader.cc ('k') | media/media.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698