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/bind.h" |
6 #include "base/test/launcher/unit_test_launcher.h" | 6 #include "base/test/launcher/unit_test_launcher.h" |
7 #include "content/app/mojo/mojo_init.h" | 7 #include "content/app/mojo/mojo_init.h" |
8 #include "content/public/test/unittest_test_suite.h" | 8 #include "content/public/test/unittest_test_suite.h" |
9 #include "content/test/content_test_suite.h" | 9 #include "content/test/content_test_suite.h" |
10 | 10 |
| 11 #if defined(OS_ANDROID) |
| 12 #include "base/android/jni_android.h" |
| 13 #include "base/test/test_file_util.h" |
| 14 #endif |
| 15 |
11 int main(int argc, char** argv) { | 16 int main(int argc, char** argv) { |
| 17 #if defined(OS_ANDROID) |
| 18 // Register JNI bindings for android. |
| 19 base::RegisterContentUriTestUtils(base::android::AttachCurrentThread()); |
| 20 #endif |
12 #if !defined(OS_IOS) | 21 #if !defined(OS_IOS) |
13 content::InitializeMojo(); | 22 content::InitializeMojo(); |
14 #endif | 23 #endif |
15 content::UnitTestTestSuite test_suite( | 24 content::UnitTestTestSuite test_suite( |
16 new content::ContentTestSuite(argc, argv)); | 25 new content::ContentTestSuite(argc, argv)); |
17 | 26 |
18 return base::LaunchUnitTests( | 27 return base::LaunchUnitTests( |
19 argc, argv, base::Bind(&content::UnitTestTestSuite::Run, | 28 argc, argv, base::Bind(&content::UnitTestTestSuite::Run, |
20 base::Unretained(&test_suite))); | 29 base::Unretained(&test_suite))); |
21 } | 30 } |
OLD | NEW |