diff options
author | thomasvl@chromium.org <thomasvl@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-03-03 16:26:03 +0000 |
---|---|---|
committer | thomasvl@chromium.org <thomasvl@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-03-03 16:26:03 +0000 |
commit | 6f33add36219e1faadea9d295b35d43841ebd508 (patch) | |
tree | bc5561b8d3cedeb13e504c971a7992a34e6d2353 /chrome/test | |
parent | abf6c7a76bc68d0a01c1665e97972b0056654a26 (diff) | |
download | chromium_src-6f33add36219e1faadea9d295b35d43841ebd508.zip chromium_src-6f33add36219e1faadea9d295b35d43841ebd508.tar.gz chromium_src-6f33add36219e1faadea9d295b35d43841ebd508.tar.bz2 |
Add a macutil for the main app bundle and override
- provide apis to get and override the app bundle
- w/in the core code, use this api for fetching the bundle
- render sandbox config
- resource bundles
- test shell font
- w/in the unittest boot straps, use the mac util to override the bundle so resources can be found.
Review URL: http://codereview.chromium.org/28214
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10798 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/test')
-rw-r--r-- | chrome/test/unit/chrome_test_suite.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/chrome/test/unit/chrome_test_suite.h b/chrome/test/unit/chrome_test_suite.h index f89030c..8dcdbf6 100644 --- a/chrome/test/unit/chrome_test_suite.h +++ b/chrome/test/unit/chrome_test_suite.h @@ -9,6 +9,9 @@ #include "base/stats_table.h" #include "base/file_util.h" +#if defined(OS_MACOSX) +#include "base/mac_util.h" +#endif #include "base/path_service.h" #include "base/scoped_nsautorelease_pool.h" #include "base/test_suite.h" @@ -47,6 +50,13 @@ protected: if (!user_data_dir.empty()) PathService::Override(chrome::DIR_USER_DATA, user_data_dir); +#if defined(OS_MACOSX) + FilePath path; + PathService::Get(base::DIR_EXE, &path); + path = path.AppendASCII("Chromium.app"); + mac_util::SetOverrideAppBundlePath(path); +#endif + // Force unittests to run using en-us so if we test against string // output, it'll pass regardless of the system language. ResourceBundle::InitSharedInstance(L"en-us"); @@ -64,6 +74,10 @@ protected: // TODO(port): Remove the #ifdef when ResourceBundle is ported. ResourceBundle::CleanupSharedInstance(); +#if defined(OS_MACOSX) + mac_util::SetOverrideAppBundle(NULL); +#endif + delete g_browser_process; g_browser_process = NULL; |