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 "base/bind.h" |
5 #include "base/command_line.h" | 6 #include "base/command_line.h" |
6 #include "base/test/test_suite.h" | 7 #include "base/test/test_suite.h" |
| 8 #include "base/test/unit_test_launcher.h" |
7 #include "build/build_config.h" | 9 #include "build/build_config.h" |
8 #include "media/base/media.h" | 10 #include "media/base/media.h" |
9 #include "media/base/media_switches.h" | 11 #include "media/base/media_switches.h" |
10 | 12 |
11 #if defined(OS_ANDROID) | 13 #if defined(OS_ANDROID) |
12 #include "base/android/jni_android.h" | 14 #include "base/android/jni_android.h" |
13 #include "media/base/android/media_jni_registrar.h" | 15 #include "media/base/android/media_jni_registrar.h" |
14 #include "ui/gl/android/gl_jni_registrar.h" | 16 #include "ui/gl/android/gl_jni_registrar.h" |
15 #endif | 17 #endif |
16 | 18 |
(...skipping 21 matching lines...) Expand all Loading... |
38 // present. | 40 // present. |
39 media::InitializeMediaLibraryForTesting(); | 41 media::InitializeMediaLibraryForTesting(); |
40 // Enable VP8 alpha support for all media tests. | 42 // Enable VP8 alpha support for all media tests. |
41 // TODO(tomfinegan): Remove this once the VP8 alpha flag is removed or | 43 // TODO(tomfinegan): Remove this once the VP8 alpha flag is removed or |
42 // negated. | 44 // negated. |
43 CommandLine* cmd_line = CommandLine::ForCurrentProcess(); | 45 CommandLine* cmd_line = CommandLine::ForCurrentProcess(); |
44 cmd_line->AppendSwitch(switches::kEnableVp8AlphaPlayback); | 46 cmd_line->AppendSwitch(switches::kEnableVp8AlphaPlayback); |
45 } | 47 } |
46 | 48 |
47 int main(int argc, char** argv) { | 49 int main(int argc, char** argv) { |
48 return TestSuiteNoAtExit(argc, argv).Run(); | 50 TestSuiteNoAtExit test_suite(argc, argv); |
| 51 |
| 52 return base::LaunchUnitTests( |
| 53 argc, argv, base::Bind(&TestSuiteNoAtExit::Run, |
| 54 base::Unretained(&test_suite))); |
49 } | 55 } |
OLD | NEW |