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

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

Issue 109743002: Move policy code into components/policy. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: moar fixes Created 7 years 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 | Annotate | Revision Log
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_store.h" 5 #include "chrome/browser/chromeos/policy/cloud_external_data_store.h"
6 6
7 #include "base/compiler_specific.h" 7 #include "base/compiler_specific.h"
8 #include "base/files/scoped_temp_dir.h" 8 #include "base/files/scoped_temp_dir.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "base/sha1.h" 10 #include "base/sha1.h"
11 #include "base/test/test_simple_task_runner.h" 11 #include "base/test/test_simple_task_runner.h"
12 #include "chrome/browser/policy/cloud/resource_cache.h" 12 #include "components/policy/core/common/cloud/resource_cache.h"
13 #include "testing/gtest/include/gtest/gtest.h" 13 #include "testing/gtest/include/gtest/gtest.h"
14 14
15 namespace policy { 15 namespace policy {
16 16
17 namespace { 17 namespace {
18 18
19 const char kKey1[] = "Key 1"; 19 const char kKey1[] = "Key 1";
20 const char kKey2[] = "Key 2"; 20 const char kKey2[] = "Key 2";
21 const char kPolicy1[] = "Test policy 1"; 21 const char kPolicy1[] = "Test policy 1";
22 const char kPolicy2[] = "Test policy 2"; 22 const char kPolicy2[] = "Test policy 2";
(...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after
189 EXPECT_TRUE(contents.empty()); 189 EXPECT_TRUE(contents.empty());
190 190
191 // Check that the part of the resource cache backing the second store is 191 // Check that the part of the resource cache backing the second store is
192 // unaffected. 192 // unaffected.
193 resource_cache_->LoadAllSubkeys(kKey2, &contents); 193 resource_cache_->LoadAllSubkeys(kKey2, &contents);
194 ASSERT_EQ(1u, contents.size()); 194 ASSERT_EQ(1u, contents.size());
195 EXPECT_EQ(kData2, contents.begin()->second); 195 EXPECT_EQ(kData2, contents.begin()->second);
196 } 196 }
197 197
198 } // namespace policy 198 } // namespace policy
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698