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

Side by Side Diff: chrome/browser/extensions/extension_service_sync_unittest.cc

Issue 2928823003: Make it possible to build without enable_supervised_users.
Patch Set: Does it still compile with the feature enabled? Created 3 years, 6 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 <stddef.h> 5 #include <stddef.h>
6 6
7 #include <map> 7 #include <map>
8 #include <memory> 8 #include <memory>
9 #include <string> 9 #include <string>
10 #include <utility> 10 #include <utility>
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
78 using extensions::Manifest; 78 using extensions::Manifest;
79 using extensions::PermissionSet; 79 using extensions::PermissionSet;
80 using extensions::ScriptingPermissionsModifier; 80 using extensions::ScriptingPermissionsModifier;
81 using extensions::WebstorePrivateIsPendingCustodianApprovalFunction; 81 using extensions::WebstorePrivateIsPendingCustodianApprovalFunction;
82 using syncer::SyncChange; 82 using syncer::SyncChange;
83 using syncer::SyncChangeList; 83 using syncer::SyncChangeList;
84 using testing::Mock; 84 using testing::Mock;
85 85
86 namespace { 86 namespace {
87 87
88 #if BUILDFLAG(ENABLE_SUPERVISED_USERS)
88 const char autoupdate[] = "ogjcoiohnmldgjemafoockdghcjciccf"; 89 const char autoupdate[] = "ogjcoiohnmldgjemafoockdghcjciccf";
90 const char good2048[] = "nmgjhmhbleinmjpbdhgajfjkbijcmgbh";
91 const char permissions_increase[] = "pgdpcfcocojkjfbgpiianjngphoopgmo";
92 #endif
93
89 const char good0[] = "behllobkkfkfnphdnhnkndlbkcpglgmj"; 94 const char good0[] = "behllobkkfkfnphdnhnkndlbkcpglgmj";
90 const char good2[] = "bjafgdebaacbbbecmhlhpofkepfkgcpa"; 95 const char good2[] = "bjafgdebaacbbbecmhlhpofkepfkgcpa";
91 const char good2048[] = "nmgjhmhbleinmjpbdhgajfjkbijcmgbh";
92 const char good_crx[] = "ldnnhddmnhbkjipkidpdiheffobcpfmf"; 96 const char good_crx[] = "ldnnhddmnhbkjipkidpdiheffobcpfmf";
93 const char page_action[] = "obcimlgaoabeegjmmpldobjndiealpln"; 97 const char page_action[] = "obcimlgaoabeegjmmpldobjndiealpln";
94 const char permissions_increase[] = "pgdpcfcocojkjfbgpiianjngphoopgmo";
95 const char theme2_crx[] = "pjpgmfcmabopnnfonnhmdjglfpjjfkbf"; 98 const char theme2_crx[] = "pjpgmfcmabopnnfonnhmdjglfpjjfkbf";
96 99
97 SyncChangeList MakeSyncChangeList(const std::string& id, 100 SyncChangeList MakeSyncChangeList(const std::string& id,
98 const sync_pb::EntitySpecifics& specifics, 101 const sync_pb::EntitySpecifics& specifics,
99 SyncChange::SyncChangeType change_type) { 102 SyncChange::SyncChangeType change_type) {
100 syncer::SyncData sync_data = 103 syncer::SyncData sync_data =
101 syncer::SyncData::CreateLocalData(id, "Name", specifics); 104 syncer::SyncData::CreateLocalData(id, "Name", specifics);
102 return SyncChangeList(1, SyncChange(FROM_HERE, change_type, sync_data)); 105 return SyncChangeList(1, SyncChange(FROM_HERE, change_type, sync_data));
103 } 106 }
104 107
(...skipping 2369 matching lines...) Expand 10 before | Expand all | Expand 10 after
2474 break; 2477 break;
2475 } 2478 }
2476 } 2479 }
2477 } 2480 }
2478 EXPECT_TRUE(found_delete); 2481 EXPECT_TRUE(found_delete);
2479 2482
2480 // Make sure there is one extension, and there are no more apps. 2483 // Make sure there is one extension, and there are no more apps.
2481 EXPECT_EQ(1u, extensions_processor.data().size()); 2484 EXPECT_EQ(1u, extensions_processor.data().size());
2482 EXPECT_TRUE(apps_processor.data().empty()); 2485 EXPECT_TRUE(apps_processor.data().empty());
2483 } 2486 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698