| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 <stddef.h> | 5 #include <stddef.h> |
| 6 | 6 |
| 7 #include "base/macros.h" | 7 #include "base/macros.h" |
| 8 #include "base/strings/string_split.h" | 8 #include "base/strings/string_split.h" |
| 9 #include "base/strings/stringprintf.h" | 9 #include "base/strings/stringprintf.h" |
| 10 #include "build/build_config.h" | 10 #include "build/build_config.h" |
| (...skipping 381 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 392 | 392 |
| 393 RunCodecSupportTest( | 393 RunCodecSupportTest( |
| 394 states_to_vary, test_states, | 394 states_to_vary, test_states, |
| 395 [](const MimeUtil::PlatformInfo& info, MimeUtil::Codec codec) { | 395 [](const MimeUtil::PlatformInfo& info, MimeUtil::Codec codec) { |
| 396 EXPECT_EQ(info.is_unified_media_pipeline_enabled, | 396 EXPECT_EQ(info.is_unified_media_pipeline_enabled, |
| 397 MimeUtil::IsCodecSupportedOnPlatform( | 397 MimeUtil::IsCodecSupportedOnPlatform( |
| 398 MimeUtil::OPUS, "audio/ogg", false, info)); | 398 MimeUtil::OPUS, "audio/ogg", false, info)); |
| 399 }); | 399 }); |
| 400 } | 400 } |
| 401 | 401 |
| 402 TEST(IsCodecSupportedOnPlatformTest, HLSDoesNotSupportMPEG2AAC) { |
| 403 // Vary all parameters; thus use default initial state. |
| 404 MimeUtil::PlatformInfo states_to_vary = VaryAllFields(); |
| 405 MimeUtil::PlatformInfo test_states; |
| 406 |
| 407 RunCodecSupportTest( |
| 408 states_to_vary, test_states, |
| 409 [](const MimeUtil::PlatformInfo& info, MimeUtil::Codec codec) { |
| 410 EXPECT_FALSE(MimeUtil::IsCodecSupportedOnPlatform( |
| 411 MimeUtil::MPEG2_AAC, "application/x-mpegurl", false, info)); |
| 412 EXPECT_FALSE(MimeUtil::IsCodecSupportedOnPlatform( |
| 413 MimeUtil::MPEG2_AAC, "application/vnd.apple.mpegurl", false, info)); |
| 414 }); |
| 415 } |
| 416 |
| 402 } // namespace internal | 417 } // namespace internal |
| 403 } // namespace media | 418 } // namespace media |
| OLD | NEW |