Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(430)

Unified Diff: chrome/browser/google/google_update_settings_unittest.cc

Issue 10909037: Redirect USER_DATA_DIR for GoogleUpdateTest and FirstRunTest. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: OVERRIDE Created 8 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/first_run/first_run_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/google/google_update_settings_unittest.cc
diff --git a/chrome/browser/google/google_update_settings_unittest.cc b/chrome/browser/google/google_update_settings_unittest.cc
index 0896a1647c226b90b7c35ac82371941609cf3a65..245e029e6a50c00d3b478fc5d28f45b8d7c8e703 100644
--- a/chrome/browser/google/google_update_settings_unittest.cc
+++ b/chrome/browser/google/google_update_settings_unittest.cc
@@ -2,12 +2,30 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include "base/basictypes.h"
+#include "base/compiler_specific.h"
+#include "base/path_service.h"
+#include "base/scoped_temp_dir.h"
#include "chrome/browser/google/google_util.h"
+#include "chrome/common/chrome_paths.h"
#include "chrome/installer/util/google_update_settings.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "testing/platform_test.h"
class GoogleUpdateTest : public PlatformTest {
+ protected:
+ GoogleUpdateTest() {}
+ virtual ~GoogleUpdateTest() {}
+
+ virtual void SetUp() OVERRIDE {
+ ASSERT_TRUE(temp_dir_.CreateUniqueTempDir());
+ PathService::Override(chrome::DIR_USER_DATA, temp_dir_.path());
+ }
+
+ private:
+ ScopedTempDir temp_dir_;
+
+ DISALLOW_COPY_AND_ASSIGN(GoogleUpdateTest);
};
TEST_F(GoogleUpdateTest, StatsConsent) {
« no previous file with comments | « chrome/browser/first_run/first_run_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698