| OLD | NEW |
| 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 "base/file_util.h" | 5 #include "base/file_util.h" |
| 6 #include "base/message_loop/message_loop_proxy.h" | 6 #include "base/message_loop/message_loop_proxy.h" |
| 7 #include "base/run_loop.h" | 7 #include "base/run_loop.h" |
| 8 #include "base/threading/thread.h" | 8 #include "base/threading/thread.h" |
| 9 #include "content/browser/browser_thread_impl.h" | 9 #include "content/browser/browser_thread_impl.h" |
| 10 #include "content/browser/gpu/shader_disk_cache.h" | 10 #include "content/browser/gpu/shader_disk_cache.h" |
| 11 #include "content/browser/quota/mock_quota_manager.h" | 11 #include "content/browser/quota/mock_quota_manager.h" |
| 12 #include "content/browser/storage_partition_impl.h" | 12 #include "content/browser/storage_partition_impl.h" |
| 13 #include "content/public/browser/local_storage_usage_info.h" | 13 #include "content/public/browser/local_storage_usage_info.h" |
| 14 #include "content/public/browser/storage_partition.h" | 14 #include "content/public/browser/storage_partition.h" |
| 15 #include "content/public/test/mock_special_storage_policy.h" | 15 #include "content/public/test/mock_special_storage_policy.h" |
| 16 #include "content/public/test/test_browser_context.h" | 16 #include "content/public/test/test_browser_context.h" |
| 17 #include "content/public/test/test_browser_thread.h" | 17 #include "content/public/test/test_browser_thread.h" |
| 18 #include "content/public/test/test_browser_thread_bundle.h" | 18 #include "content/public/test/test_browser_thread_bundle.h" |
| 19 #include "net/base/test_completion_callback.h" | 19 #include "net/base/test_completion_callback.h" |
| 20 #include "net/cookies/cookie_monster.h" | 20 #include "net/cookies/cookie_monster.h" |
| 21 #include "net/url_request/url_request_context.h" | 21 #include "net/url_request/url_request_context.h" |
| 22 #include "net/url_request/url_request_context_getter.h" | 22 #include "net/url_request/url_request_context_getter.h" |
| 23 #include "testing/gtest/include/gtest/gtest.h" | 23 #include "testing/gtest/include/gtest/gtest.h" |
| 24 #include "webkit/browser/quota/quota_manager.h" | 24 #include "storage/browser/quota/quota_manager.h" |
| 25 | 25 |
| 26 namespace content { | 26 namespace content { |
| 27 namespace { | 27 namespace { |
| 28 | 28 |
| 29 const int kDefaultClientId = 42; | 29 const int kDefaultClientId = 42; |
| 30 const char kCacheKey[] = "key"; | 30 const char kCacheKey[] = "key"; |
| 31 const char kCacheValue[] = "cached value"; | 31 const char kCacheValue[] = "cached value"; |
| 32 | 32 |
| 33 const char kTestOrigin1[] = "http://host1:1/"; | 33 const char kTestOrigin1[] = "http://host1:1/"; |
| 34 const char kTestOrigin2[] = "http://host2:1/"; | 34 const char kTestOrigin2[] = "http://host2:1/"; |
| (...skipping 886 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 921 &run_loop)); | 921 &run_loop)); |
| 922 run_loop.Run(); | 922 run_loop.Run(); |
| 923 | 923 |
| 924 // kOrigin1 and kOrigin2 do not have age more than a week. | 924 // kOrigin1 and kOrigin2 do not have age more than a week. |
| 925 EXPECT_FALSE(tester.DOMStorageExistsForOrigin(kOrigin1)); | 925 EXPECT_FALSE(tester.DOMStorageExistsForOrigin(kOrigin1)); |
| 926 EXPECT_FALSE(tester.DOMStorageExistsForOrigin(kOrigin2)); | 926 EXPECT_FALSE(tester.DOMStorageExistsForOrigin(kOrigin2)); |
| 927 EXPECT_TRUE(tester.DOMStorageExistsForOrigin(kOrigin3)); | 927 EXPECT_TRUE(tester.DOMStorageExistsForOrigin(kOrigin3)); |
| 928 } | 928 } |
| 929 | 929 |
| 930 } // namespace content | 930 } // namespace content |
| OLD | NEW |