| OLD | NEW |
| 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 "media/filters/pipeline_integration_test_base.h" | 5 #include "media/filters/pipeline_integration_test_base.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
| 10 #include "base/strings/string_util.h" | 10 #include "base/strings/string_util.h" |
| (...skipping 1131 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1142 32768, | 1142 32768, |
| 1143 base::TimeDelta::FromMilliseconds(167), | 1143 base::TimeDelta::FromMilliseconds(167), |
| 1144 base::TimeDelta::FromMilliseconds(1668), | 1144 base::TimeDelta::FromMilliseconds(1668), |
| 1145 0x1C896, 65536)); | 1145 0x1C896, 65536)); |
| 1146 } | 1146 } |
| 1147 | 1147 |
| 1148 // Verify that Opus audio in WebM containers can be played back. | 1148 // Verify that Opus audio in WebM containers can be played back. |
| 1149 TEST_F(PipelineIntegrationTest, BasicPlayback_AudioOnly_Opus_WebM) { | 1149 TEST_F(PipelineIntegrationTest, BasicPlayback_AudioOnly_Opus_WebM) { |
| 1150 ASSERT_TRUE(Start(GetTestDataFilePath("bear-opus-end-trimming.webm"), | 1150 ASSERT_TRUE(Start(GetTestDataFilePath("bear-opus-end-trimming.webm"), |
| 1151 PIPELINE_OK)); | 1151 PIPELINE_OK)); |
| 1152 EXPECT_EQ(1u, pipeline_->GetBufferedTimeRanges().size()); | |
| 1153 EXPECT_EQ(0, pipeline_->GetBufferedTimeRanges().start(0).InMilliseconds()); | |
| 1154 EXPECT_EQ(kOpusEndTrimmingWebMFileDurationMs, | |
| 1155 pipeline_->GetBufferedTimeRanges().end(0).InMilliseconds()); | |
| 1156 Play(); | 1152 Play(); |
| 1157 ASSERT_TRUE(WaitUntilOnEnded()); | 1153 ASSERT_TRUE(WaitUntilOnEnded()); |
| 1158 } | 1154 } |
| 1159 | 1155 |
| 1160 // Verify that VP9 video in WebM containers can be played back. | 1156 // Verify that VP9 video in WebM containers can be played back. |
| 1161 TEST_F(PipelineIntegrationTest, BasicPlayback_VideoOnly_VP9_WebM) { | 1157 TEST_F(PipelineIntegrationTest, BasicPlayback_VideoOnly_VP9_WebM) { |
| 1162 ASSERT_TRUE(Start(GetTestDataFilePath("bear-vp9.webm"), | 1158 ASSERT_TRUE(Start(GetTestDataFilePath("bear-vp9.webm"), |
| 1163 PIPELINE_OK)); | 1159 PIPELINE_OK)); |
| 1164 Play(); | 1160 Play(); |
| 1165 ASSERT_TRUE(WaitUntilOnEnded()); | 1161 ASSERT_TRUE(WaitUntilOnEnded()); |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1197 // Verify that VP8 video with inband text track can be played back. | 1193 // Verify that VP8 video with inband text track can be played back. |
| 1198 TEST_F(PipelineIntegrationTest, | 1194 TEST_F(PipelineIntegrationTest, |
| 1199 BasicPlayback_VP8_WebVTT_WebM) { | 1195 BasicPlayback_VP8_WebVTT_WebM) { |
| 1200 ASSERT_TRUE(Start(GetTestDataFilePath("bear-vp8-webvtt.webm"), | 1196 ASSERT_TRUE(Start(GetTestDataFilePath("bear-vp8-webvtt.webm"), |
| 1201 PIPELINE_OK)); | 1197 PIPELINE_OK)); |
| 1202 Play(); | 1198 Play(); |
| 1203 ASSERT_TRUE(WaitUntilOnEnded()); | 1199 ASSERT_TRUE(WaitUntilOnEnded()); |
| 1204 } | 1200 } |
| 1205 | 1201 |
| 1206 } // namespace media | 1202 } // namespace media |
| OLD | NEW |