| 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 "chrome/test/base/chrome_test_suite.h" | 5 #include "chrome/test/base/chrome_test_suite.h" |
| 6 | 6 |
| 7 #if defined(OS_CHROMEOS) | 7 #if defined(OS_CHROMEOS) |
| 8 #include <stdio.h> | 8 #include <stdio.h> |
| 9 #include <unistd.h> | 9 #include <unistd.h> |
| 10 #endif | 10 #endif |
| (...skipping 23 matching lines...) Expand all Loading... |
| 34 #include "ui/base/resource/resource_bundle.h" | 34 #include "ui/base/resource/resource_bundle.h" |
| 35 #include "ui/base/resource/resource_handle.h" | 35 #include "ui/base/resource/resource_handle.h" |
| 36 | 36 |
| 37 #if defined(OS_ANDROID) | 37 #if defined(OS_ANDROID) |
| 38 #include "base/android/jni_android.h" | 38 #include "base/android/jni_android.h" |
| 39 #include "chrome/browser/android/chrome_jni_registrar.h" | 39 #include "chrome/browser/android/chrome_jni_registrar.h" |
| 40 #include "net/android/net_jni_registrar.h" | 40 #include "net/android/net_jni_registrar.h" |
| 41 #include "ui/android/ui_jni_registrar.h" | 41 #include "ui/android/ui_jni_registrar.h" |
| 42 #endif | 42 #endif |
| 43 | 43 |
| 44 #if defined(OS_CHROMEOS) |
| 45 #include "chromeos/chromeos_paths.h" |
| 46 #endif |
| 47 |
| 44 #if defined(OS_MACOSX) | 48 #if defined(OS_MACOSX) |
| 45 #include "base/mac/bundle_locations.h" | 49 #include "base/mac/bundle_locations.h" |
| 46 #include "base/mac/scoped_nsautorelease_pool.h" | 50 #include "base/mac/scoped_nsautorelease_pool.h" |
| 47 #if !defined(OS_IOS) | 51 #if !defined(OS_IOS) |
| 48 #include "base/mac/mac_util.h" | 52 #include "base/mac/mac_util.h" |
| 49 #include "chrome/browser/chrome_browser_application_mac.h" | 53 #include "chrome/browser/chrome_browser_application_mac.h" |
| 50 #endif // !defined(OS_IOS) | 54 #endif // !defined(OS_IOS) |
| 51 #endif | 55 #endif |
| 52 | 56 |
| 53 #if defined(OS_POSIX) | 57 #if defined(OS_POSIX) |
| (...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 202 #endif | 206 #endif |
| 203 | 207 |
| 204 #if defined(OS_ANDROID) | 208 #if defined(OS_ANDROID) |
| 205 // Register JNI bindings for android. | 209 // Register JNI bindings for android. |
| 206 net::android::RegisterJni(base::android::AttachCurrentThread()); | 210 net::android::RegisterJni(base::android::AttachCurrentThread()); |
| 207 ui::android::RegisterJni(base::android::AttachCurrentThread()); | 211 ui::android::RegisterJni(base::android::AttachCurrentThread()); |
| 208 chrome::android::RegisterJni(base::android::AttachCurrentThread()); | 212 chrome::android::RegisterJni(base::android::AttachCurrentThread()); |
| 209 #endif | 213 #endif |
| 210 | 214 |
| 211 chrome::RegisterPathProvider(); | 215 chrome::RegisterPathProvider(); |
| 216 #if defined(OS_CHROMEOS) |
| 217 chromeos::RegisterPathProvider(); |
| 218 #endif |
| 212 if (!browser_dir_.empty()) { | 219 if (!browser_dir_.empty()) { |
| 213 PathService::Override(base::DIR_EXE, browser_dir_); | 220 PathService::Override(base::DIR_EXE, browser_dir_); |
| 214 PathService::Override(base::DIR_MODULE, browser_dir_); | 221 PathService::Override(base::DIR_MODULE, browser_dir_); |
| 215 } | 222 } |
| 216 | 223 |
| 217 #if !defined(OS_IOS) | 224 #if !defined(OS_IOS) |
| 218 extensions::RegisterPathProvider(); | 225 extensions::RegisterPathProvider(); |
| 219 | 226 |
| 220 if (!content::GetCurrentTestLauncherDelegate()) { | 227 if (!content::GetCurrentTestLauncherDelegate()) { |
| 221 // Only want to do this for unit tests. For browser tests, this won't create | 228 // Only want to do this for unit tests. For browser tests, this won't create |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 279 #if defined(OS_MACOSX) && !defined(OS_IOS) | 286 #if defined(OS_MACOSX) && !defined(OS_IOS) |
| 280 base::mac::SetOverrideFrameworkBundle(NULL); | 287 base::mac::SetOverrideFrameworkBundle(NULL); |
| 281 #endif | 288 #endif |
| 282 | 289 |
| 283 base::StatsTable::set_current(NULL); | 290 base::StatsTable::set_current(NULL); |
| 284 stats_table_.reset(); | 291 stats_table_.reset(); |
| 285 RemoveSharedMemoryFile(stats_filename_); | 292 RemoveSharedMemoryFile(stats_filename_); |
| 286 | 293 |
| 287 base::TestSuite::Shutdown(); | 294 base::TestSuite::Shutdown(); |
| 288 } | 295 } |
| OLD | NEW |