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

Side by Side Diff: media/formats/mp4/aac_unittest.cc

Issue 1235793005: Deprecate LogCB in favor of using MediaLog (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address comments and attempt to fix Android compilation Created 5 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 unified diff | Download patch
« no previous file with comments | « media/formats/mp4/aac.cc ('k') | media/formats/mp4/box_definitions.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "media/formats/mp4/aac.h" 5 #include "media/formats/mp4/aac.h"
6 6
7 #include "testing/gtest/include/gtest/gtest.h" 7 #include "testing/gtest/include/gtest/gtest.h"
8 8
9 namespace media { 9 namespace media {
10 10
11 namespace mp4 { 11 namespace mp4 {
12 12
13 class AACTest : public testing::Test { 13 class AACTest : public testing::Test {
14 public: 14 public:
15 bool Parse(const std::vector<uint8>& data) { 15 bool Parse(const std::vector<uint8>& data) {
16 return aac_.Parse(data, LogCB()); 16 return aac_.Parse(data, new MediaLog());
17 } 17 }
18 18
19 AAC aac_; 19 AAC aac_;
20 }; 20 };
21 21
22 TEST_F(AACTest, BasicProfileTest) { 22 TEST_F(AACTest, BasicProfileTest) {
23 uint8 buffer[] = {0x12, 0x10}; 23 uint8 buffer[] = {0x12, 0x10};
24 std::vector<uint8> data; 24 std::vector<uint8> data;
25 25
26 data.assign(buffer, buffer + sizeof(buffer)); 26 data.assign(buffer, buffer + sizeof(buffer));
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 137
138 EXPECT_FALSE(Parse(data)); 138 EXPECT_FALSE(Parse(data));
139 139
140 data[1] = 0x08; 140 data[1] = 0x08;
141 EXPECT_TRUE(Parse(data)); 141 EXPECT_TRUE(Parse(data));
142 } 142 }
143 143
144 } // namespace mp4 144 } // namespace mp4
145 145
146 } // namespace media 146 } // namespace media
OLDNEW
« no previous file with comments | « media/formats/mp4/aac.cc ('k') | media/formats/mp4/box_definitions.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698