OLD | NEW |
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 <stack> | 5 #include <stack> |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/bind_helpers.h" | 8 #include "base/bind_helpers.h" |
9 #include "base/callback.h" | 9 #include "base/callback.h" |
10 #include "base/file_util.h" | 10 #include "base/file_util.h" |
(...skipping 1750 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1761 // The URLRequestJob will eventually fail when it gets to disk | 1761 // The URLRequestJob will eventually fail when it gets to disk |
1762 // cache initialization. | 1762 // cache initialization. |
1763 backend_->RegisterHost(2); | 1763 backend_->RegisterHost(2); |
1764 AppCacheHost* host2 = backend_->GetHost(2); | 1764 AppCacheHost* host2 = backend_->GetHost(2); |
1765 GURL manifest_url = MockHttpServer::GetMockUrl("manifest"); | 1765 GURL manifest_url = MockHttpServer::GetMockUrl("manifest"); |
1766 request_ = service()->request_context()->CreateRequest( | 1766 request_ = service()->request_context()->CreateRequest( |
1767 manifest_url, net::DEFAULT_PRIORITY, NULL, NULL); | 1767 manifest_url, net::DEFAULT_PRIORITY, NULL, NULL); |
1768 AppCacheInterceptor::SetExtraRequestInfo( | 1768 AppCacheInterceptor::SetExtraRequestInfo( |
1769 request_.get(), service_.get(), | 1769 request_.get(), service_.get(), |
1770 backend_->process_id(), host2->host_id(), | 1770 backend_->process_id(), host2->host_id(), |
1771 ResourceType::MAIN_FRAME); | 1771 RESOURCE_TYPE_MAIN_FRAME); |
1772 request_->Start(); | 1772 request_->Start(); |
1773 } | 1773 } |
1774 | 1774 |
1775 PushNextTask(base::Bind( | 1775 PushNextTask(base::Bind( |
1776 &AppCacheStorageImplTest::Verify_Reinitialized, | 1776 &AppCacheStorageImplTest::Verify_Reinitialized, |
1777 base::Unretained(this), | 1777 base::Unretained(this), |
1778 test_case)); | 1778 test_case)); |
1779 } | 1779 } |
1780 | 1780 |
1781 void Verify_Reinitialized(ReinitTestCase test_case) { | 1781 void Verify_Reinitialized(ReinitTestCase test_case) { |
(...skipping 236 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2018 RunTestOnIOThread(&AppCacheStorageImplTest::Reinitialize2); | 2018 RunTestOnIOThread(&AppCacheStorageImplTest::Reinitialize2); |
2019 } | 2019 } |
2020 | 2020 |
2021 TEST_F(AppCacheStorageImplTest, Reinitialize3) { | 2021 TEST_F(AppCacheStorageImplTest, Reinitialize3) { |
2022 RunTestOnIOThread(&AppCacheStorageImplTest::Reinitialize3); | 2022 RunTestOnIOThread(&AppCacheStorageImplTest::Reinitialize3); |
2023 } | 2023 } |
2024 | 2024 |
2025 // That's all folks! | 2025 // That's all folks! |
2026 | 2026 |
2027 } // namespace content | 2027 } // namespace content |
OLD | NEW |