| 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 <string> | 5 #include <string> |
| 6 | 6 |
| 7 #include "base/message_loop/message_loop.h" | 7 #include "base/message_loop/message_loop.h" |
| 8 #include "testing/gtest/include/gtest/gtest.h" | 8 #include "testing/gtest/include/gtest/gtest.h" |
| 9 #include "webkit/browser/appcache/appcache.h" | 9 #include "webkit/browser/appcache/appcache.h" |
| 10 #include "webkit/browser/appcache/appcache_group.h" | 10 #include "webkit/browser/appcache/appcache_group.h" |
| (...skipping 20 matching lines...) Expand all Loading... |
| 31 | 31 |
| 32 virtual void OnStatusChanged(const std::vector<int>& host_ids, | 32 virtual void OnStatusChanged(const std::vector<int>& host_ids, |
| 33 appcache::Status status) OVERRIDE { | 33 appcache::Status status) OVERRIDE { |
| 34 } | 34 } |
| 35 | 35 |
| 36 virtual void OnEventRaised(const std::vector<int>& host_ids, | 36 virtual void OnEventRaised(const std::vector<int>& host_ids, |
| 37 appcache::EventID event_id) OVERRIDE { | 37 appcache::EventID event_id) OVERRIDE { |
| 38 } | 38 } |
| 39 | 39 |
| 40 virtual void OnErrorEventRaised(const std::vector<int>& host_ids, | 40 virtual void OnErrorEventRaised(const std::vector<int>& host_ids, |
| 41 const std::string& message) OVERRIDE { | 41 const std::string& message, |
| 42 } | 42 const std::string& reason, |
| 43 const GURL& url, |
| 44 int status) OVERRIDE {} |
| 43 | 45 |
| 44 virtual void OnProgressEventRaised(const std::vector<int>& host_ids, | 46 virtual void OnProgressEventRaised(const std::vector<int>& host_ids, |
| 45 const GURL& url, | 47 const GURL& url, |
| 46 int num_total, int num_complete) OVERRIDE { | 48 int num_total, int num_complete) OVERRIDE { |
| 47 } | 49 } |
| 48 | 50 |
| 49 virtual void OnLogMessage(int host_id, appcache::LogLevel log_level, | 51 virtual void OnLogMessage(int host_id, appcache::LogLevel log_level, |
| 50 const std::string& message) OVERRIDE { | 52 const std::string& message) OVERRIDE { |
| 51 } | 53 } |
| 52 | 54 |
| (...skipping 240 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 293 EXPECT_TRUE(group->FindObserver(&host, group->observers_)); | 295 EXPECT_TRUE(group->FindObserver(&host, group->observers_)); |
| 294 | 296 |
| 295 // Delete update to cause it to complete. Verify host is notified. | 297 // Delete update to cause it to complete. Verify host is notified. |
| 296 delete group->update_job_; | 298 delete group->update_job_; |
| 297 EXPECT_EQ(AppCacheGroup::IDLE, group->update_status_); | 299 EXPECT_EQ(AppCacheGroup::IDLE, group->update_status_); |
| 298 EXPECT_TRUE(group->restart_update_task_.IsCancelled()); | 300 EXPECT_TRUE(group->restart_update_task_.IsCancelled()); |
| 299 EXPECT_TRUE(host.update_completed_); | 301 EXPECT_TRUE(host.update_completed_); |
| 300 } | 302 } |
| 301 | 303 |
| 302 } // namespace appcache | 304 } // namespace appcache |
| OLD | NEW |