OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/bind.h" | 5 #include "base/bind.h" |
6 #include "base/bind_helpers.h" | 6 #include "base/bind_helpers.h" |
7 #include "base/memory/scoped_ptr.h" | 7 #include "base/memory/scoped_ptr.h" |
8 #include "base/message_loop/message_loop.h" | 8 #include "base/message_loop/message_loop.h" |
9 #include "net/url_request/url_request.h" | 9 #include "net/url_request/url_request.h" |
10 #include "testing/gtest/include/gtest/gtest.h" | 10 #include "testing/gtest/include/gtest/gtest.h" |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
53 appcache::Status status) OVERRIDE { | 53 appcache::Status status) OVERRIDE { |
54 last_status_changed_ = status; | 54 last_status_changed_ = status; |
55 } | 55 } |
56 | 56 |
57 virtual void OnEventRaised(const std::vector<int>& host_ids, | 57 virtual void OnEventRaised(const std::vector<int>& host_ids, |
58 appcache::EventID event_id) OVERRIDE { | 58 appcache::EventID event_id) OVERRIDE { |
59 last_event_id_ = event_id; | 59 last_event_id_ = event_id; |
60 } | 60 } |
61 | 61 |
62 virtual void OnErrorEventRaised(const std::vector<int>& host_ids, | 62 virtual void OnErrorEventRaised(const std::vector<int>& host_ids, |
63 const std::string& message) OVERRIDE { | 63 const std::string& message, |
| 64 const std::string& reason, |
| 65 const GURL& url, |
| 66 int status) OVERRIDE { |
64 last_event_id_ = ERROR_EVENT; | 67 last_event_id_ = ERROR_EVENT; |
65 } | 68 } |
66 | 69 |
67 virtual void OnProgressEventRaised(const std::vector<int>& host_ids, | 70 virtual void OnProgressEventRaised(const std::vector<int>& host_ids, |
68 const GURL& url, | 71 const GURL& url, |
69 int num_total, | 72 int num_total, |
70 int num_complete) OVERRIDE { | 73 int num_complete) OVERRIDE { |
71 last_event_id_ = PROGRESS_EVENT; | 74 last_event_id_ = PROGRESS_EVENT; |
72 } | 75 } |
73 | 76 |
(...skipping 456 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
530 EXPECT_EQ(&mock_frontend_, host.frontend()); | 533 EXPECT_EQ(&mock_frontend_, host.frontend()); |
531 EXPECT_EQ(NULL, host.associated_cache()); | 534 EXPECT_EQ(NULL, host.associated_cache()); |
532 EXPECT_FALSE(host.is_selection_pending()); | 535 EXPECT_FALSE(host.is_selection_pending()); |
533 EXPECT_TRUE(host.preferred_manifest_url().is_empty()); | 536 EXPECT_TRUE(host.preferred_manifest_url().is_empty()); |
534 } | 537 } |
535 EXPECT_EQ(0, mock_quota_proxy->GetInUseCount(kDocAndOriginUrl)); | 538 EXPECT_EQ(0, mock_quota_proxy->GetInUseCount(kDocAndOriginUrl)); |
536 service_.set_quota_manager_proxy(NULL); | 539 service_.set_quota_manager_proxy(NULL); |
537 } | 540 } |
538 | 541 |
539 } // namespace appcache | 542 } // namespace appcache |
OLD | NEW |