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

Side by Side Diff: chrome/browser/chromeos/extensions/device_local_account_external_policy_loader_unittest.cc

Issue 100573002: Move directory creation functions to base namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: 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/extensions/device_local_account_external_polic y_loader.h" 5 #include "chrome/browser/chromeos/extensions/device_local_account_external_polic y_loader.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/callback.h" 9 #include "base/callback.h"
10 #include "base/file_util.h" 10 #include "base/file_util.h"
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after
120 : thread_bundle_(content::TestBrowserThreadBundle::IO_MAINLOOP) { 120 : thread_bundle_(content::TestBrowserThreadBundle::IO_MAINLOOP) {
121 } 121 }
122 122
123 DeviceLocalAccountExternalPolicyLoaderTest:: 123 DeviceLocalAccountExternalPolicyLoaderTest::
124 ~DeviceLocalAccountExternalPolicyLoaderTest() { 124 ~DeviceLocalAccountExternalPolicyLoaderTest() {
125 } 125 }
126 126
127 void DeviceLocalAccountExternalPolicyLoaderTest::SetUp() { 127 void DeviceLocalAccountExternalPolicyLoaderTest::SetUp() {
128 ASSERT_TRUE(temp_dir_.CreateUniqueTempDir()); 128 ASSERT_TRUE(temp_dir_.CreateUniqueTempDir());
129 cache_dir_ = temp_dir_.path().Append(kCacheDir); 129 cache_dir_ = temp_dir_.path().Append(kCacheDir);
130 ASSERT_TRUE(file_util::CreateDirectoryAndGetError(cache_dir_, NULL)); 130 ASSERT_TRUE(base::CreateDirectoryAndGetError(cache_dir_, NULL));
131 request_context_getter_ = 131 request_context_getter_ =
132 new net::TestURLRequestContextGetter(base::MessageLoopProxy::current()); 132 new net::TestURLRequestContextGetter(base::MessageLoopProxy::current());
133 TestingBrowserProcess::GetGlobal()->SetSystemRequestContext( 133 TestingBrowserProcess::GetGlobal()->SetSystemRequestContext(
134 request_context_getter_.get()); 134 request_context_getter_.get());
135 ASSERT_TRUE(PathService::Get(chrome::DIR_TEST_DATA, &test_dir_)); 135 ASSERT_TRUE(PathService::Get(chrome::DIR_TEST_DATA, &test_dir_));
136 136
137 loader_ = new DeviceLocalAccountExternalPolicyLoader(&store_, cache_dir_); 137 loader_ = new DeviceLocalAccountExternalPolicyLoader(&store_, cache_dir_);
138 provider_.reset(new extensions::ExternalProviderImpl( 138 provider_.reset(new extensions::ExternalProviderImpl(
139 &visitor_, 139 &visitor_,
140 loader_, 140 loader_,
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after
300 loader_->StopCache(shutdown_run_loop.QuitClosure()); 300 loader_->StopCache(shutdown_run_loop.QuitClosure());
301 VerifyAndResetVisitorCallExpectations(); 301 VerifyAndResetVisitorCallExpectations();
302 302
303 // Spin the loop until the cache shutdown callback is invoked. Verify that at 303 // Spin the loop until the cache shutdown callback is invoked. Verify that at
304 // that point, no further file I/O tasks are pending. 304 // that point, no further file I/O tasks are pending.
305 shutdown_run_loop.Run(); 305 shutdown_run_loop.Run();
306 EXPECT_TRUE(base::MessageLoop::current()->IsIdleForTesting()); 306 EXPECT_TRUE(base::MessageLoop::current()->IsIdleForTesting());
307 } 307 }
308 308
309 } // namespace chromeos 309 } // namespace chromeos
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/drive/file_system_unittest.cc ('k') | chrome/browser/chromeos/extensions/external_cache.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698