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 <deque> | 5 #include <deque> |
6 | 6 |
7 #include "base/file_path.h" | 7 #include "base/file_path.h" |
8 #include "base/file_util.h" | 8 #include "base/file_util.h" |
9 #include "base/path_service.h" | 9 #include "base/path_service.h" |
10 #include "base/threading/thread.h" | 10 #include "base/threading/thread.h" |
(...skipping 412 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
423 message_loop_.RunAllPending(); | 423 message_loop_.RunAllPending(); |
424 } | 424 } |
425 | 425 |
426 // A mocked callback specialization for calling Read(). Since RunWithParams() | 426 // A mocked callback specialization for calling Read(). Since RunWithParams() |
427 // is mocked we don't need to pass in object or method pointers. | 427 // is mocked we don't need to pass in object or method pointers. |
428 class MockReadCB : public base::RefCountedThreadSafe<MockReadCB> { | 428 class MockReadCB : public base::RefCountedThreadSafe<MockReadCB> { |
429 public: | 429 public: |
430 MockReadCB() {} | 430 MockReadCB() {} |
431 | 431 |
432 MOCK_METHOD0(OnDelete, void()); | 432 MOCK_METHOD0(OnDelete, void()); |
433 MOCK_METHOD1(Run, void(const scoped_refptr<Buffer>& buffer)); | 433 MOCK_METHOD1(Run, void(const scoped_refptr<DecoderBuffer>& buffer)); |
434 | 434 |
435 protected: | 435 protected: |
436 virtual ~MockReadCB() { | 436 virtual ~MockReadCB() { |
437 OnDelete(); | 437 OnDelete(); |
438 } | 438 } |
439 | 439 |
440 private: | 440 private: |
441 friend class base::RefCountedThreadSafe<MockReadCB>; | 441 friend class base::RefCountedThreadSafe<MockReadCB>; |
442 | 442 |
443 DISALLOW_COPY_AND_ASSIGN(MockReadCB); | 443 DISALLOW_COPY_AND_ASSIGN(MockReadCB); |
(...skipping 323 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
767 TEST_F(FFmpegDemuxerTest, UnsupportedVideoSupportedAudioDemux) { | 767 TEST_F(FFmpegDemuxerTest, UnsupportedVideoSupportedAudioDemux) { |
768 CreateDemuxer("vorbis_audio_wmv_video.mkv"); | 768 CreateDemuxer("vorbis_audio_wmv_video.mkv"); |
769 InitializeDemuxer(); | 769 InitializeDemuxer(); |
770 | 770 |
771 // Ensure the expected streams are present. | 771 // Ensure the expected streams are present. |
772 EXPECT_FALSE(demuxer_->GetStream(DemuxerStream::VIDEO)); | 772 EXPECT_FALSE(demuxer_->GetStream(DemuxerStream::VIDEO)); |
773 EXPECT_TRUE(demuxer_->GetStream(DemuxerStream::AUDIO)); | 773 EXPECT_TRUE(demuxer_->GetStream(DemuxerStream::AUDIO)); |
774 } | 774 } |
775 | 775 |
776 } // namespace media | 776 } // namespace media |
OLD | NEW |