diff options
author | erikkay@google.com <erikkay@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-12-05 20:26:29 +0000 |
---|---|---|
committer | erikkay@google.com <erikkay@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-12-05 20:26:29 +0000 |
commit | f66c110c118bf7e5c386d49a5f4e83d948441b45 (patch) | |
tree | d052b77548d3c11450a7b886809aaf11c8f46a55 /chrome/browser/extensions | |
parent | d8b258c5e97adbc8e73dd73b319d1cdacb4c15d7 (diff) | |
download | chromium_src-f66c110c118bf7e5c386d49a5f4e83d948441b45.zip chromium_src-f66c110c118bf7e5c386d49a5f4e83d948441b45.tar.gz chromium_src-f66c110c118bf7e5c386d49a5f4e83d948441b45.tar.bz2 |
fix chrome_paths to make some test dirs relative to base::DIR_SOURCE_ROOT
rather than chrome::DIR_APP. DIR_APP is in different relative locations on
different platforms while DIR_SOURCE_ROOT is the same, so this allows us to
share code and be correct on all platforms.
Also, enable extensions_service_unittest for Mac and Linux and add an
NSAutoreleasePool to ChromeTestSuite (which is now being used by
run_all_unittests on Mac and Linux per my earlier checkin).
Review URL: http://codereview.chromium.org/13177
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@6445 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/extensions')
-rw-r--r-- | chrome/browser/extensions/extensions_service_unittest.cc | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/chrome/browser/extensions/extensions_service_unittest.cc b/chrome/browser/extensions/extensions_service_unittest.cc index 22e891d..da86f27 100644 --- a/chrome/browser/extensions/extensions_service_unittest.cc +++ b/chrome/browser/extensions/extensions_service_unittest.cc @@ -13,9 +13,7 @@ #include "chrome/common/chrome_paths.h" #include "chrome/common/json_value_serializer.h" #include "testing/gtest/include/gtest/gtest.h" - -class ExtensionsServiceTest : public testing::Test { -}; +#include "testing/platform_test.h" // A mock implementation of ExtensionsServiceFrontendInterface for testing the @@ -50,10 +48,11 @@ class ExtensionsServiceTestFrontend std::vector<std::wstring> errors_; }; +// make the test a PlatformTest to setup autorelease pools properly on mac +typedef PlatformTest ExtensionsServiceTest; // Test loading extensions from the profile directory. TEST_F(ExtensionsServiceTest, LoadAllExtensionsFromDirectory) { -#if defined(OS_WIN) std::wstring extensions_dir; ASSERT_TRUE(PathService::Get(chrome::DIR_TEST_DATA, &extensions_dir)); FilePath manifest_path = FilePath::FromWStringHack(extensions_dir).Append( @@ -94,5 +93,4 @@ TEST_F(ExtensionsServiceTest, LoadAllExtensionsFromDirectory) { EXPECT_EQ(std::wstring(L""), frontend->extensions()->at(1)->description()); EXPECT_EQ(0u, frontend->extensions()->at(1)->content_scripts().size()); -#endif }; |