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

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

Issue 11471006: Log MediaSource parsing errors to the MediaLog so they can appear in chrome:media-internals. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix nit. Created 8 years 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 | Annotate | Revision Log
« no previous file with comments | « media/filters/chunk_demuxer_unittest.cc ('k') | media/filters/source_buffer_stream.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 (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/string_util.h" 8 #include "base/string_util.h"
9 #include "media/base/decoder_buffer.h" 9 #include "media/base/decoder_buffer.h"
10 #include "media/base/decryptor_client.h" 10 #include "media/base/decryptor_client.h"
(...skipping 26 matching lines...) Expand all
37 class MockMediaSource { 37 class MockMediaSource {
38 public: 38 public:
39 MockMediaSource(const std::string& filename, const std::string& mimetype, 39 MockMediaSource(const std::string& filename, const std::string& mimetype,
40 int initial_append_size) 40 int initial_append_size)
41 : file_path_(GetTestDataFilePath(filename)), 41 : file_path_(GetTestDataFilePath(filename)),
42 current_position_(0), 42 current_position_(0),
43 initial_append_size_(initial_append_size), 43 initial_append_size_(initial_append_size),
44 mimetype_(mimetype) { 44 mimetype_(mimetype) {
45 chunk_demuxer_ = new ChunkDemuxer( 45 chunk_demuxer_ = new ChunkDemuxer(
46 base::Bind(&MockMediaSource::DemuxerOpened, base::Unretained(this)), 46 base::Bind(&MockMediaSource::DemuxerOpened, base::Unretained(this)),
47 base::Bind(&MockMediaSource::DemuxerNeedKey, base::Unretained(this))); 47 base::Bind(&MockMediaSource::DemuxerNeedKey, base::Unretained(this)),
48 LogCB());
48 49
49 file_data_ = ReadTestDataFile(filename); 50 file_data_ = ReadTestDataFile(filename);
50 51
51 if (initial_append_size_ == kAppendWholeFile) 52 if (initial_append_size_ == kAppendWholeFile)
52 initial_append_size_ = file_data_->GetDataSize(); 53 initial_append_size_ = file_data_->GetDataSize();
53 54
54 DCHECK_GT(initial_append_size_, 0); 55 DCHECK_GT(initial_append_size_, 0);
55 DCHECK_LE(initial_append_size_, file_data_->GetDataSize()); 56 DCHECK_LE(initial_append_size_, file_data_->GetDataSize());
56 } 57 }
57 58
(...skipping 382 matching lines...) Expand 10 before | Expand all | Expand 10 after
440 // Verify video decoder & renderer can handle aborted demuxer reads. 441 // Verify video decoder & renderer can handle aborted demuxer reads.
441 TEST_F(PipelineIntegrationTest, ChunkDemuxerAbortRead_VideoOnly) { 442 TEST_F(PipelineIntegrationTest, ChunkDemuxerAbortRead_VideoOnly) {
442 ASSERT_TRUE(TestSeekDuringRead("bear-320x240-video-only.webm", kVideoOnlyWebM, 443 ASSERT_TRUE(TestSeekDuringRead("bear-320x240-video-only.webm", kVideoOnlyWebM,
443 32768, 444 32768,
444 base::TimeDelta::FromMilliseconds(200), 445 base::TimeDelta::FromMilliseconds(200),
445 base::TimeDelta::FromMilliseconds(1668), 446 base::TimeDelta::FromMilliseconds(1668),
446 0x1C896, 65536)); 447 0x1C896, 65536));
447 } 448 }
448 449
449 } // namespace media 450 } // namespace media
OLDNEW
« no previous file with comments | « media/filters/chunk_demuxer_unittest.cc ('k') | media/filters/source_buffer_stream.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698