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 #ifndef MEDIA_TEST_PIPELINE_INTEGRATION_TEST_BASE_H_ | 5 #ifndef MEDIA_TEST_PIPELINE_INTEGRATION_TEST_BASE_H_ |
6 #define MEDIA_TEST_PIPELINE_INTEGRATION_TEST_BASE_H_ | 6 #define MEDIA_TEST_PIPELINE_INTEGRATION_TEST_BASE_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include "base/md5.h" | 10 #include "base/md5.h" |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
69 // Starts the pipeline (optionally with a CdmContext), returning the final | 69 // Starts the pipeline (optionally with a CdmContext), returning the final |
70 // status code after it has started. |filename| points at a test file located | 70 // status code after it has started. |filename| points at a test file located |
71 // under media/test/data/. | 71 // under media/test/data/. |
72 PipelineStatus Start(const std::string& filename); | 72 PipelineStatus Start(const std::string& filename); |
73 PipelineStatus Start(const std::string& filename, CdmContext* cdm_context); | 73 PipelineStatus Start(const std::string& filename, CdmContext* cdm_context); |
74 | 74 |
75 // Starts the pipeline in a particular mode for advanced testing and | 75 // Starts the pipeline in a particular mode for advanced testing and |
76 // benchmarking purposes (e.g., underflow is disabled to ensure consistent | 76 // benchmarking purposes (e.g., underflow is disabled to ensure consistent |
77 // hashes). May be combined using the bitwise or operator (and as such must | 77 // hashes). May be combined using the bitwise or operator (and as such must |
78 // have values that are powers of two). | 78 // have values that are powers of two). |
79 enum TestTypeFlags { kHashed = 1, kClockless = 2 }; | 79 enum TestTypeFlags { kNormal = 0, kHashed = 1, kClockless = 2 }; |
80 PipelineStatus Start(const std::string& filename, uint8_t test_type); | 80 PipelineStatus Start(const std::string& filename, uint8_t test_type); |
81 | 81 |
82 void Play(); | 82 void Play(); |
83 void Pause(); | 83 void Pause(); |
84 bool Seek(base::TimeDelta seek_time); | 84 bool Seek(base::TimeDelta seek_time); |
85 bool Suspend(); | 85 bool Suspend(); |
86 bool Resume(base::TimeDelta seek_time); | 86 bool Resume(base::TimeDelta seek_time); |
87 void Stop(); | 87 void Stop(); |
88 bool WaitUntilCurrentTimeIsAfter(const base::TimeDelta& wait_time); | 88 bool WaitUntilCurrentTimeIsAfter(const base::TimeDelta& wait_time); |
89 | 89 |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
148 MOCK_METHOD1(DecryptorAttached, void(bool)); | 148 MOCK_METHOD1(DecryptorAttached, void(bool)); |
149 MOCK_METHOD2(OnAddTextTrack, | 149 MOCK_METHOD2(OnAddTextTrack, |
150 void(const TextTrackConfig& config, | 150 void(const TextTrackConfig& config, |
151 const AddTextTrackDoneCB& done_cb)); | 151 const AddTextTrackDoneCB& done_cb)); |
152 MOCK_METHOD0(OnWaitingForDecryptionKey, void(void)); | 152 MOCK_METHOD0(OnWaitingForDecryptionKey, void(void)); |
153 }; | 153 }; |
154 | 154 |
155 } // namespace media | 155 } // namespace media |
156 | 156 |
157 #endif // MEDIA_TEST_PIPELINE_INTEGRATION_TEST_BASE_H_ | 157 #endif // MEDIA_TEST_PIPELINE_INTEGRATION_TEST_BASE_H_ |
OLD | NEW |