OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "base/test/test_reg_util_win.h" | 5 #include "base/test/test_reg_util_win.h" |
6 | 6 |
7 #include "base/guid.h" | 7 #include "base/guid.h" |
8 #include "base/logging.h" | 8 #include "base/logging.h" |
9 #include "base/strings/string_number_conversions.h" | 9 #include "base/strings/string_number_conversions.h" |
10 #include "base/strings/string_split.h" | 10 #include "base/strings/string_split.h" |
11 #include "base/strings/string_util.h" | 11 #include "base/strings/string_util.h" |
12 #include "base/strings/utf_string_conversions.h" | 12 #include "base/strings/utf_string_conversions.h" |
13 #include "testing/gtest/include/gtest/gtest.h" | 13 #include "testing/gtest/googletest/include/gtest/gtest.h" |
14 | 14 |
15 namespace registry_util { | 15 namespace registry_util { |
16 | 16 |
17 namespace { | 17 namespace { |
18 | 18 |
19 const wchar_t kTimestampDelimiter[] = L"$"; | 19 const wchar_t kTimestampDelimiter[] = L"$"; |
20 const wchar_t kTempTestKeyPath[] = L"Software\\Chromium\\TempTestKeys"; | 20 const wchar_t kTempTestKeyPath[] = L"Software\\Chromium\\TempTestKeys"; |
21 | 21 |
22 void DeleteStaleTestKeys(const base::Time& now, | 22 void DeleteStaleTestKeys(const base::Time& now, |
23 const base::string16& test_key_root) { | 23 const base::string16& test_key_root) { |
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
99 base::string16 key_path = GenerateTempKeyPath(test_key_root_, timestamp_); | 99 base::string16 key_path = GenerateTempKeyPath(test_key_root_, timestamp_); |
100 overrides_.push_back(new ScopedRegistryKeyOverride(override, key_path)); | 100 overrides_.push_back(new ScopedRegistryKeyOverride(override, key_path)); |
101 } | 101 } |
102 | 102 |
103 base::string16 GenerateTempKeyPath() { | 103 base::string16 GenerateTempKeyPath() { |
104 return GenerateTempKeyPath(base::string16(kTempTestKeyPath), | 104 return GenerateTempKeyPath(base::string16(kTempTestKeyPath), |
105 base::Time::Now()); | 105 base::Time::Now()); |
106 } | 106 } |
107 | 107 |
108 } // namespace registry_util | 108 } // namespace registry_util |
OLD | NEW |