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

Side by Side Diff: content/browser/quota/quota_backend_impl_unittest.cc

Issue 2316043002: //content: Change ScopedTempDir::path() to GetPath() (Closed)
Patch Set: Just rebased Created 4 years, 3 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 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 "storage/browser/fileapi/quota/quota_backend_impl.h" 5 #include "storage/browser/fileapi/quota/quota_backend_impl.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 8
9 #include <memory> 9 #include <memory>
10 #include <string> 10 #include <string>
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
95 class QuotaBackendImplTest : public testing::Test { 95 class QuotaBackendImplTest : public testing::Test {
96 public: 96 public:
97 QuotaBackendImplTest() 97 QuotaBackendImplTest()
98 : file_system_usage_cache_(file_task_runner()), 98 : file_system_usage_cache_(file_task_runner()),
99 quota_manager_proxy_(new MockQuotaManagerProxy) {} 99 quota_manager_proxy_(new MockQuotaManagerProxy) {}
100 100
101 void SetUp() override { 101 void SetUp() override {
102 ASSERT_TRUE(data_dir_.CreateUniqueTempDir()); 102 ASSERT_TRUE(data_dir_.CreateUniqueTempDir());
103 in_memory_env_.reset(leveldb::NewMemEnv(leveldb::Env::Default())); 103 in_memory_env_.reset(leveldb::NewMemEnv(leveldb::Env::Default()));
104 file_util_.reset(ObfuscatedFileUtil::CreateForTesting( 104 file_util_.reset(ObfuscatedFileUtil::CreateForTesting(
105 NULL, data_dir_.path(), in_memory_env_.get(), file_task_runner())); 105 NULL, data_dir_.GetPath(), in_memory_env_.get(), file_task_runner()));
106 backend_.reset(new QuotaBackendImpl(file_task_runner(), 106 backend_.reset(new QuotaBackendImpl(file_task_runner(),
107 file_util_.get(), 107 file_util_.get(),
108 &file_system_usage_cache_, 108 &file_system_usage_cache_,
109 quota_manager_proxy_.get())); 109 quota_manager_proxy_.get()));
110 } 110 }
111 111
112 void TearDown() override { 112 void TearDown() override {
113 backend_.reset(); 113 backend_.reset();
114 quota_manager_proxy_ = NULL; 114 quota_manager_proxy_ = NULL;
115 file_util_.reset(); 115 file_util_.reset();
(...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after
267 uint32_t dirty = 0; 267 uint32_t dirty = 0;
268 ASSERT_TRUE(file_system_usage_cache_.GetDirty(path, &dirty)); 268 ASSERT_TRUE(file_system_usage_cache_.GetDirty(path, &dirty));
269 EXPECT_EQ(1u, dirty); 269 EXPECT_EQ(1u, dirty);
270 270
271 backend_->DecrementDirtyCount(GURL(kOrigin), type); 271 backend_->DecrementDirtyCount(GURL(kOrigin), type);
272 ASSERT_TRUE(file_system_usage_cache_.GetDirty(path, &dirty)); 272 ASSERT_TRUE(file_system_usage_cache_.GetDirty(path, &dirty));
273 EXPECT_EQ(0u, dirty); 273 EXPECT_EQ(0u, dirty);
274 } 274 }
275 275
276 } // namespace content 276 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/quota/mock_quota_manager_unittest.cc ('k') | content/browser/quota/quota_database_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698