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

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: 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 | « no previous file | 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..f730672c1115e2d43563bb7834cf58e6d6981d85 100644
--- a/chrome/browser/google/google_update_settings_unittest.cc
+++ b/chrome/browser/google/google_update_settings_unittest.cc
@@ -2,12 +2,29 @@
// 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() {}
Lei Zhang 2012/08/31 20:49:48 needs a virtual destructor as well.
Mattias Nissler (ping if slow) 2012/08/31 20:56:18 Done.
+
+ virtual void SetUp() OVERRIDE {
+ ASSERT_TRUE(temp_dir_.CreateUniqueTempDir());
+ PathService::Override(chrome::DIR_USER_DATA, temp_dir_.path());
+ }
+
+ ScopedTempDir temp_dir_;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(GoogleUpdateTest);
};
TEST_F(GoogleUpdateTest, StatsConsent) {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698