| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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/blink/webmediaplayer_impl.h" | 5 #include "media/blink/webmediaplayer_impl.h" |
| 6 | 6 |
| 7 #include <stdint.h> | 7 #include <stdint.h> |
| 8 | 8 |
| 9 #include <memory> | 9 #include <memory> |
| 10 | 10 |
| (...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 181 bool is_idle_ = false; | 181 bool is_idle_ = false; |
| 182 bool is_stale_ = false; | 182 bool is_stale_ = false; |
| 183 bool is_hidden_ = false; | 183 bool is_hidden_ = false; |
| 184 bool is_closed_ = false; | 184 bool is_closed_ = false; |
| 185 }; | 185 }; |
| 186 | 186 |
| 187 class WebMediaPlayerImplTest : public testing::Test { | 187 class WebMediaPlayerImplTest : public testing::Test { |
| 188 public: | 188 public: |
| 189 WebMediaPlayerImplTest() | 189 WebMediaPlayerImplTest() |
| 190 : media_thread_("MediaThreadForTest"), | 190 : media_thread_("MediaThreadForTest"), |
| 191 web_view_(blink::WebView::create(nullptr, | 191 web_view_(blink::WebView::create(blink::WebPageVisibilityStateVisible)), |
| 192 blink::WebPageVisibilityStateVisible)), | |
| 193 web_local_frame_( | 192 web_local_frame_( |
| 194 blink::WebLocalFrame::create(blink::WebTreeScopeType::Document, | 193 blink::WebLocalFrame::create(blink::WebTreeScopeType::Document, |
| 195 &web_frame_client_, | 194 &web_frame_client_, |
| 196 nullptr, | 195 nullptr, |
| 197 nullptr)), | 196 nullptr)), |
| 198 media_log_(new MediaLog()), | 197 media_log_(new MediaLog()), |
| 199 audio_parameters_(TestAudioParameters::Normal()) { | 198 audio_parameters_(TestAudioParameters::Normal()) { |
| 200 web_view_->setMainFrame(web_local_frame_); | 199 web_view_->setMainFrame(web_local_frame_); |
| 201 media_thread_.StartAndWaitForTesting(); | 200 media_thread_.StartAndWaitForTesting(); |
| 202 } | 201 } |
| (...skipping 715 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 918 | 917 |
| 919 INSTANTIATE_TEST_CASE_P(BackgroundBehaviorTestInstances, | 918 INSTANTIATE_TEST_CASE_P(BackgroundBehaviorTestInstances, |
| 920 WebMediaPlayerImplBackgroundBehaviorTest, | 919 WebMediaPlayerImplBackgroundBehaviorTest, |
| 921 ::testing::Combine(::testing::Bool(), | 920 ::testing::Combine(::testing::Bool(), |
| 922 ::testing::Bool(), | 921 ::testing::Bool(), |
| 923 ::testing::Values(5, 300), | 922 ::testing::Values(5, 300), |
| 924 ::testing::Values(5, 100), | 923 ::testing::Values(5, 100), |
| 925 ::testing::Bool())); | 924 ::testing::Bool())); |
| 926 | 925 |
| 927 } // namespace media | 926 } // namespace media |
| OLD | NEW |