| 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 "base/basictypes.h" | 5 #include "base/basictypes.h" |
| 6 #include "base/compiler_specific.h" | 6 #include "base/compiler_specific.h" |
| 7 #include "base/file_util.h" | 7 #include "base/file_util.h" |
| 8 #include "base/memory/ref_counted.h" | 8 #include "base/memory/ref_counted.h" |
| 9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
| 10 #include "base/path_service.h" | 10 #include "base/path_service.h" |
| (...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 142 error_message_ = error_message; | 142 error_message_ = error_message; |
| 143 results_ = results; | 143 results_ = results; |
| 144 Quit(); | 144 Quit(); |
| 145 } | 145 } |
| 146 | 146 |
| 147 CrxUpdateItem UpdateCheckerTest::BuildCrxUpdateItem() { | 147 CrxUpdateItem UpdateCheckerTest::BuildCrxUpdateItem() { |
| 148 CrxComponent crx_component; | 148 CrxComponent crx_component; |
| 149 crx_component.name = "test_jebg"; | 149 crx_component.name = "test_jebg"; |
| 150 crx_component.pk_hash.assign(jebg_hash, jebg_hash + arraysize(jebg_hash)); | 150 crx_component.pk_hash.assign(jebg_hash, jebg_hash + arraysize(jebg_hash)); |
| 151 crx_component.installer = NULL; | 151 crx_component.installer = NULL; |
| 152 crx_component.observer = NULL; | |
| 153 crx_component.version = base::Version("0.9"); | 152 crx_component.version = base::Version("0.9"); |
| 154 crx_component.fingerprint = "fp1"; | 153 crx_component.fingerprint = "fp1"; |
| 155 | 154 |
| 156 CrxUpdateItem crx_update_item; | 155 CrxUpdateItem crx_update_item; |
| 157 crx_update_item.status = CrxUpdateItem::kNew; | 156 crx_update_item.status = CrxUpdateItem::kNew; |
| 158 crx_update_item.id = "jebgalgnebhfojomionfpkfelancnnkf"; | 157 crx_update_item.id = "jebgalgnebhfojomionfpkfelancnnkf"; |
| 159 crx_update_item.component = crx_component; | 158 crx_update_item.component = crx_component; |
| 160 | 159 |
| 161 return crx_update_item; | 160 return crx_update_item; |
| 162 } | 161 } |
| (...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 227 EXPECT_EQ(1, post_interceptor_->GetCount()) | 226 EXPECT_EQ(1, post_interceptor_->GetCount()) |
| 228 << post_interceptor_->GetRequestsAsString(); | 227 << post_interceptor_->GetRequestsAsString(); |
| 229 | 228 |
| 230 EXPECT_NE(0, error_); | 229 EXPECT_NE(0, error_); |
| 231 EXPECT_STREQ("network error", error_message_.c_str()); | 230 EXPECT_STREQ("network error", error_message_.c_str()); |
| 232 EXPECT_EQ(0ul, results_.list.size()); | 231 EXPECT_EQ(0ul, results_.list.size()); |
| 233 } | 232 } |
| 234 | 233 |
| 235 } // namespace component_updater | 234 } // namespace component_updater |
| 236 | 235 |
| OLD | NEW |