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

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

Issue 2815743002: Move a couple of blob tests next to the files they cover. (Closed)
Patch Set: Fix gn check, take 2. Created 3 years, 8 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 <stddef.h> 5 #include <stddef.h>
6 #include <stdint.h> 6 #include <stdint.h>
7 7
8 #include <algorithm> 8 #include <algorithm>
9 #include <memory> 9 #include <memory>
10 #include <set> 10 #include <set>
11 #include <sstream> 11 #include <sstream>
12 #include <tuple> 12 #include <tuple>
13 #include <vector> 13 #include <vector>
14 14
15 #include "base/bind.h" 15 #include "base/bind.h"
16 #include "base/files/file_util.h" 16 #include "base/files/file_util.h"
17 #include "base/files/scoped_temp_dir.h" 17 #include "base/files/scoped_temp_dir.h"
18 #include "base/macros.h" 18 #include "base/macros.h"
19 #include "base/memory/ptr_util.h" 19 #include "base/memory/ptr_util.h"
20 #include "base/memory/weak_ptr.h" 20 #include "base/memory/weak_ptr.h"
21 #include "base/run_loop.h" 21 #include "base/run_loop.h"
22 #include "base/stl_util.h" 22 #include "base/stl_util.h"
23 #include "base/sys_info.h" 23 #include "base/sys_info.h"
24 #include "base/test/histogram_tester.h" 24 #include "base/test/histogram_tester.h"
25 #include "base/test/scoped_task_environment.h" 25 #include "base/test/scoped_task_environment.h"
26 #include "base/threading/thread_task_runner_handle.h" 26 #include "base/threading/thread_task_runner_handle.h"
27 #include "base/time/time.h" 27 #include "base/time/time.h"
28 #include "content/public/test/mock_special_storage_policy.h"
29 #include "content/public/test/mock_storage_client.h" 28 #include "content/public/test/mock_storage_client.h"
30 #include "storage/browser/quota/quota_database.h" 29 #include "storage/browser/quota/quota_database.h"
31 #include "storage/browser/quota/quota_manager.h" 30 #include "storage/browser/quota/quota_manager.h"
32 #include "storage/browser/quota/quota_manager_proxy.h" 31 #include "storage/browser/quota/quota_manager_proxy.h"
32 #include "storage/browser/test/mock_special_storage_policy.h"
33 #include "testing/gtest/include/gtest/gtest.h" 33 #include "testing/gtest/include/gtest/gtest.h"
34 #include "url/gurl.h" 34 #include "url/gurl.h"
35 35
36 using storage::kQuotaErrorAbort; 36 using storage::kQuotaErrorAbort;
37 using storage::kQuotaErrorInvalidModification; 37 using storage::kQuotaErrorInvalidModification;
38 using storage::kQuotaErrorNotSupported; 38 using storage::kQuotaErrorNotSupported;
39 using storage::kQuotaStatusOk; 39 using storage::kQuotaStatusOk;
40 using storage::kQuotaStatusUnknown; 40 using storage::kQuotaStatusUnknown;
41 using storage::kStorageTypePersistent; 41 using storage::kStorageTypePersistent;
42 using storage::kStorageTypeSyncable; 42 using storage::kStorageTypeSyncable;
(...skipping 2204 matching lines...) Expand 10 before | Expand all | Expand 10 after
2247 EXPECT_EQ(available_space() + usage(), quota()); 2247 EXPECT_EQ(available_space() + usage(), quota());
2248 2248
2249 GetUsageAndQuotaForWebApps(GURL("http://foo.com/"), kTemp); 2249 GetUsageAndQuotaForWebApps(GURL("http://foo.com/"), kTemp);
2250 base::RunLoop().RunUntilIdle(); 2250 base::RunLoop().RunUntilIdle();
2251 EXPECT_EQ(kQuotaStatusOk, status()); 2251 EXPECT_EQ(kQuotaStatusOk, status());
2252 EXPECT_EQ(10, usage()); 2252 EXPECT_EQ(10, usage());
2253 EXPECT_EQ(available_space() + usage(), quota()); 2253 EXPECT_EQ(available_space() + usage(), quota());
2254 } 2254 }
2255 2255
2256 } // namespace content 2256 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/quota/quota_database_unittest.cc ('k') | content/browser/quota/storage_monitor_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698