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

Side by Side Diff: extensions/browser/extension_pref_value_map_unittest.cc

Issue 2664753002: Remove base::StringValue (Closed)
Patch Set: Rebase Created 3 years, 9 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 unified diff | Download patch
« no previous file with comments | « extensions/browser/event_router_unittest.cc ('k') | extensions/browser/extension_prefs.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "extensions/browser/extension_pref_value_map.h" 5 #include "extensions/browser/extension_pref_value_map.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 8
9 #include <memory> 9 #include <memory>
10 10
11 #include "base/macros.h" 11 #include "base/macros.h"
12 #include "base/memory/ref_counted.h" 12 #include "base/memory/ref_counted.h"
13 #include "base/values.h" 13 #include "base/values.h"
14 #include "components/prefs/pref_store_observer_mock.h" 14 #include "components/prefs/pref_store_observer_mock.h"
15 #include "testing/gmock/include/gmock/gmock.h" 15 #include "testing/gmock/include/gmock/gmock.h"
16 #include "testing/gtest/include/gtest/gtest.h" 16 #include "testing/gtest/include/gtest/gtest.h"
17 17
18 namespace { 18 namespace {
19 const char kExt1[] = "ext1"; 19 const char kExt1[] = "ext1";
20 const char kExt2[] = "ext2"; 20 const char kExt2[] = "ext2";
21 const char kExt3[] = "ext3"; 21 const char kExt3[] = "ext3";
22 22
23 const char kPref1[] = "path1.subpath"; 23 const char kPref1[] = "path1.subpath";
24 const char kPref2[] = "path2"; 24 const char kPref2[] = "path2";
25 const char kPref3[] = "path3"; 25 const char kPref3[] = "path3";
26 const char kPref4[] = "path4"; 26 const char kPref4[] = "path4";
27 } // namespace 27 } // namespace
28 28
29 static base::Value* CreateVal(const char* str) { 29 static base::Value* CreateVal(const char* str) {
30 return new base::StringValue(str); 30 return new base::Value(str);
31 } 31 }
32 32
33 static base::Time CreateTime(int64_t t) { 33 static base::Time CreateTime(int64_t t) {
34 return base::Time::FromInternalValue(t); 34 return base::Time::FromInternalValue(t);
35 } 35 }
36 36
37 template <typename BASECLASS> 37 template <typename BASECLASS>
38 class ExtensionPrefValueMapTestBase : public BASECLASS { 38 class ExtensionPrefValueMapTestBase : public BASECLASS {
39 public: 39 public:
40 static const extensions::ExtensionPrefsScope kRegular = 40 static const extensions::ExtensionPrefsScope kRegular =
(...skipping 395 matching lines...) Expand 10 before | Expand all | Expand 10 after
436 OverrideIncognitoTestCase(false, false, 1, 2, 3, 0, 5, 0, 0, 0, 5, 0), 436 OverrideIncognitoTestCase(false, false, 1, 2, 3, 0, 5, 0, 0, 0, 5, 0),
437 OverrideIncognitoTestCase(false, false, 1, 0, 0, 0, 0, 6, 0, 0, 6, 0), 437 OverrideIncognitoTestCase(false, false, 1, 0, 0, 0, 0, 6, 0, 0, 6, 0),
438 OverrideIncognitoTestCase(false, false, 1, 0, 3, 0, 5, 6, 0, 0, 6, 0), 438 OverrideIncognitoTestCase(false, false, 1, 0, 3, 0, 5, 6, 0, 0, 6, 0),
439 OverrideIncognitoTestCase(false, false, 1, 0, 0, 4, 5, 6, 0, 0, 6, 0), 439 OverrideIncognitoTestCase(false, false, 1, 0, 0, 4, 5, 6, 0, 0, 6, 0),
440 OverrideIncognitoTestCase(false, false, 1, 0, 0, 0, 0, 0, 7, 0, 1, 0), 440 OverrideIncognitoTestCase(false, false, 1, 0, 0, 0, 0, 0, 7, 0, 1, 0),
441 OverrideIncognitoTestCase(false, false, 1, 2, 0, 0, 5, 0, 7, 0, 5, 0), 441 OverrideIncognitoTestCase(false, false, 1, 2, 0, 0, 5, 0, 7, 0, 5, 0),
442 OverrideIncognitoTestCase(false, false, 1, 2, 0, 0, 5, 0, 0, 8, 5, 0), 442 OverrideIncognitoTestCase(false, false, 1, 2, 0, 0, 5, 0, 0, 8, 5, 0),
443 OverrideIncognitoTestCase(false, false, 1, 2, 0, 0, 5, 0, 7, 8, 5, 0), 443 OverrideIncognitoTestCase(false, false, 1, 2, 0, 0, 5, 0, 7, 8, 5, 0),
444 OverrideIncognitoTestCase(false, false, 1, 2, 3, 0, 0, 6, 7, 0, 6, 0) 444 OverrideIncognitoTestCase(false, false, 1, 2, 3, 0, 0, 6, 7, 0, 6, 0)
445 )); 445 ));
OLDNEW
« no previous file with comments | « extensions/browser/event_router_unittest.cc ('k') | extensions/browser/extension_prefs.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698