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

Side by Side Diff: media/test/pipeline_integration_test.cc

Issue 2515553002: Fix mimetype mappings for FLAC support. (Closed)
Patch Set: Comments. Created 4 years, 1 month 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/filters/ffmpeg_demuxer_unittest.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 <stddef.h> 5 #include <stddef.h>
6 #include <stdint.h> 6 #include <stdint.h>
7 7
8 #include <memory> 8 #include <memory>
9 #include <utility> 9 #include <utility>
10 10
(...skipping 1183 matching lines...) Expand 10 before | Expand all | Expand 10 after
1194 1194
1195 ASSERT_EQ(PIPELINE_OK, Start("bear-320x240-av_enc-av.webm", 1195 ASSERT_EQ(PIPELINE_OK, Start("bear-320x240-av_enc-av.webm",
1196 encrypted_media.GetCdmContext())); 1196 encrypted_media.GetCdmContext()));
1197 1197
1198 Play(); 1198 Play();
1199 1199
1200 ASSERT_TRUE(WaitUntilOnEnded()); 1200 ASSERT_TRUE(WaitUntilOnEnded());
1201 Stop(); 1201 Stop();
1202 } 1202 }
1203 1203
1204 TEST_F(PipelineIntegrationTest, FlacPlaybackHashed) {
1205 ASSERT_EQ(PIPELINE_OK, Start("sfx.flac", kHashed));
1206 Play();
1207 ASSERT_TRUE(WaitUntilOnEnded());
1208 EXPECT_HASH_EQ(std::string(kNullVideoHash), GetVideoHash());
1209 EXPECT_HASH_EQ("3.03,2.86,2.99,3.31,3.57,4.06,", GetAudioHash());
1210 }
1211
1204 TEST_F(PipelineIntegrationTest, BasicPlayback_MediaSource) { 1212 TEST_F(PipelineIntegrationTest, BasicPlayback_MediaSource) {
1205 MockMediaSource source("bear-320x240.webm", kWebM, 219229); 1213 MockMediaSource source("bear-320x240.webm", kWebM, 219229);
1206 EXPECT_EQ(PIPELINE_OK, StartPipelineWithMediaSource(&source)); 1214 EXPECT_EQ(PIPELINE_OK, StartPipelineWithMediaSource(&source));
1207 source.EndOfStream(); 1215 source.EndOfStream();
1208 1216
1209 EXPECT_EQ(1u, pipeline_->GetBufferedTimeRanges().size()); 1217 EXPECT_EQ(1u, pipeline_->GetBufferedTimeRanges().size());
1210 EXPECT_EQ(0, pipeline_->GetBufferedTimeRanges().start(0).InMilliseconds()); 1218 EXPECT_EQ(0, pipeline_->GetBufferedTimeRanges().start(0).InMilliseconds());
1211 EXPECT_EQ(k320WebMFileDurationMs, 1219 EXPECT_EQ(k320WebMFileDurationMs,
1212 pipeline_->GetBufferedTimeRanges().end(0).InMilliseconds()); 1220 pipeline_->GetBufferedTimeRanges().end(0).InMilliseconds());
1213 1221
(...skipping 1286 matching lines...) Expand 10 before | Expand all | Expand 10 after
2500 2508
2501 TEST_F(PipelineIntegrationTest, BasicPlaybackPositiveStartTime) { 2509 TEST_F(PipelineIntegrationTest, BasicPlaybackPositiveStartTime) {
2502 ASSERT_EQ(PIPELINE_OK, Start("nonzero-start-time.webm")); 2510 ASSERT_EQ(PIPELINE_OK, Start("nonzero-start-time.webm"));
2503 Play(); 2511 Play();
2504 ASSERT_TRUE(WaitUntilOnEnded()); 2512 ASSERT_TRUE(WaitUntilOnEnded());
2505 ASSERT_EQ(base::TimeDelta::FromMicroseconds(396000), 2513 ASSERT_EQ(base::TimeDelta::FromMicroseconds(396000),
2506 demuxer_->GetStartTime()); 2514 demuxer_->GetStartTime());
2507 } 2515 }
2508 2516
2509 } // namespace media 2517 } // namespace media
OLDNEW
« no previous file with comments | « media/filters/ffmpeg_demuxer_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698