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

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

Issue 10447035: Introducing DecoderBuffer and general Buffer cleanup. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: s/2011/2012/ Created 8 years, 6 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 | Annotate | Revision Log
« no previous file with comments | « media/filters/ffmpeg_demuxer.cc ('k') | media/filters/ffmpeg_h264_bitstream_converter.cc » ('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 <algorithm> 5 #include <algorithm>
6 #include <deque> 6 #include <deque>
7 #include <string> 7 #include <string>
8 8
9 #include "base/file_path.h" 9 #include "base/file_path.h"
10 #include "base/file_util.h" 10 #include "base/file_util.h"
(...skipping 424 matching lines...) Expand 10 before | Expand all | Expand 10 after
435 message_loop_.RunAllPending(); 435 message_loop_.RunAllPending();
436 } 436 }
437 437
438 // A mocked callback specialization for calling Read(). Since RunWithParams() 438 // A mocked callback specialization for calling Read(). Since RunWithParams()
439 // is mocked we don't need to pass in object or method pointers. 439 // is mocked we don't need to pass in object or method pointers.
440 class MockReadCB : public base::RefCountedThreadSafe<MockReadCB> { 440 class MockReadCB : public base::RefCountedThreadSafe<MockReadCB> {
441 public: 441 public:
442 MockReadCB() {} 442 MockReadCB() {}
443 443
444 MOCK_METHOD0(OnDelete, void()); 444 MOCK_METHOD0(OnDelete, void());
445 MOCK_METHOD1(Run, void(const scoped_refptr<Buffer>& buffer)); 445 MOCK_METHOD1(Run, void(const scoped_refptr<DecoderBuffer>& buffer));
446 446
447 protected: 447 protected:
448 virtual ~MockReadCB() { 448 virtual ~MockReadCB() {
449 OnDelete(); 449 OnDelete();
450 } 450 }
451 451
452 private: 452 private:
453 friend class base::RefCountedThreadSafe<MockReadCB>; 453 friend class base::RefCountedThreadSafe<MockReadCB>;
454 454
455 DISALLOW_COPY_AND_ASSIGN(MockReadCB); 455 DISALLOW_COPY_AND_ASSIGN(MockReadCB);
(...skipping 317 matching lines...) Expand 10 before | Expand all | Expand 10 after
773 TEST_F(FFmpegDemuxerTest, UnsupportedVideoSupportedAudioDemux) { 773 TEST_F(FFmpegDemuxerTest, UnsupportedVideoSupportedAudioDemux) {
774 CreateDemuxer("vorbis_audio_wmv_video.mkv"); 774 CreateDemuxer("vorbis_audio_wmv_video.mkv");
775 InitializeDemuxer(); 775 InitializeDemuxer();
776 776
777 // Ensure the expected streams are present. 777 // Ensure the expected streams are present.
778 EXPECT_FALSE(demuxer_->GetStream(DemuxerStream::VIDEO)); 778 EXPECT_FALSE(demuxer_->GetStream(DemuxerStream::VIDEO));
779 EXPECT_TRUE(demuxer_->GetStream(DemuxerStream::AUDIO)); 779 EXPECT_TRUE(demuxer_->GetStream(DemuxerStream::AUDIO));
780 } 780 }
781 781
782 } // namespace media 782 } // namespace media
OLDNEW
« no previous file with comments | « media/filters/ffmpeg_demuxer.cc ('k') | media/filters/ffmpeg_h264_bitstream_converter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698