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

Side by Side Diff: chrome/browser/chromeos/policy/cloud_external_data_manager_base_test_util.cc

Issue 2257103002: Re-write many calls to WrapUnique() with MakeUnique() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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 unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 "chrome/browser/chromeos/policy/cloud_external_data_manager_base_test_u til.h" 5 #include "chrome/browser/chromeos/policy/cloud_external_data_manager_base_test_u til.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/callback.h" 9 #include "base/callback.h"
10 #include "base/memory/ptr_util.h" 10 #include "base/memory/ptr_util.h"
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 } 42 }
43 43
44 void SetExternalDataReference(CloudPolicyCore* core, 44 void SetExternalDataReference(CloudPolicyCore* core,
45 const std::string& policy, 45 const std::string& policy,
46 std::unique_ptr<base::DictionaryValue> metadata) { 46 std::unique_ptr<base::DictionaryValue> metadata) {
47 CloudPolicyStore* store = core->store(); 47 CloudPolicyStore* store = core->store();
48 ASSERT_TRUE(store); 48 ASSERT_TRUE(store);
49 PolicyMap policy_map; 49 PolicyMap policy_map;
50 policy_map.Set(policy, POLICY_LEVEL_MANDATORY, POLICY_SCOPE_USER, 50 policy_map.Set(policy, POLICY_LEVEL_MANDATORY, POLICY_SCOPE_USER,
51 POLICY_SOURCE_CLOUD, std::move(metadata), 51 POLICY_SOURCE_CLOUD, std::move(metadata),
52 base::WrapUnique(new ExternalDataFetcher( 52 base::MakeUnique<ExternalDataFetcher>(
53 store->external_data_manager(), policy))); 53 store->external_data_manager(), policy));
54 store->SetPolicyMapForTesting(policy_map); 54 store->SetPolicyMapForTesting(policy_map);
55 } 55 }
56 56
57 } // namespace test 57 } // namespace test
58 } // namespace policy 58 } // namespace policy
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698