summaryrefslogtreecommitdiffstats
path: root/rlz/test/rlz_test_helpers.h
diff options
context:
space:
mode:
authorgrt@chromium.org <grt@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-11-14 07:43:20 +0000
committergrt@chromium.org <grt@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-11-14 07:43:20 +0000
commit20402235d708145f61c1fe41a4d7b8ddc35a15be (patch)
tree9acfda4ab3c09257f8515019c63a4981c49859c5 /rlz/test/rlz_test_helpers.h
parentb7c04c11491d6c37c22b9ebb49696cafefb38c09 (diff)
downloadchromium_src-20402235d708145f61c1fe41a4d7b8ddc35a15be.zip
chromium_src-20402235d708145f61c1fe41a4d7b8ddc35a15be.tar.gz
chromium_src-20402235d708145f61c1fe41a4d7b8ddc35a15be.tar.bz2
Use RegistryOverrideManager properly in RLZ tests.
Previously, rlz/test/rlz_test_helpers.cc and chrome/browser/rlz/rlz_unittest.cc each did somewhat different things to prepare the registry for tests. Now, rlz_test_helpers.cc does the prep the right way using RegistryOverrideManager and rlz_unittests.cc uses rlz_test_helpers.cc. This unblocks the refactor in r234367 that was reverted in r234627. BUG=314800 R=rogerta@chromium.org, tommycli@chromium.org Review URL: https://codereview.chromium.org/63153009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@235090 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'rlz/test/rlz_test_helpers.h')
-rw-r--r--rlz/test/rlz_test_helpers.h13
1 files changed, 10 insertions, 3 deletions
diff --git a/rlz/test/rlz_test_helpers.h b/rlz/test/rlz_test_helpers.h
index a78764f..ec067fe 100644
--- a/rlz/test/rlz_test_helpers.h
+++ b/rlz/test/rlz_test_helpers.h
@@ -14,20 +14,27 @@
#include "base/files/scoped_temp_dir.h"
#endif
+#if defined(OS_WIN)
+#include "base/test/test_reg_util_win.h"
+#endif
+
class RlzLibTestNoMachineState : public ::testing::Test {
protected:
virtual void SetUp() OVERRIDE;
virtual void TearDown() OVERRIDE;
-
#if defined(OS_POSIX)
- base::ScopedTempDir temp_dir_;
+ base::ScopedTempDir temp_dir_;
+#endif
+
+#if defined(OS_WIN)
+ registry_util::RegistryOverrideManager override_manager_;
#endif
};
class RlzLibTestBase : public RlzLibTestNoMachineState {
+ protected:
virtual void SetUp() OVERRIDE;
};
-
#endif // RLZ_TEST_RLZ_TEST_HELPERS_H