| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 "chrome/install_static/product_install_details.h" | 5 #include "chrome/install_static/product_install_details.h" |
| 6 | 6 |
| 7 #include "base/base_paths.h" | 7 #include "base/base_paths.h" |
| 8 #include "base/files/file_path.h" | 8 #include "base/files/file_path.h" |
| 9 #include "base/i18n/case_conversion.h" | 9 #include "base/i18n/case_conversion.h" |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| (...skipping 265 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 276 {L"250-doom", L"dev"}, | 276 {L"250-doom", L"dev"}, |
| 277 }; | 277 }; |
| 278 | 278 |
| 279 for (const auto& ap_and_channel : kApChannels) { | 279 for (const auto& ap_and_channel : kApChannels) { |
| 280 SetAp(ap_and_channel.first); | 280 SetAp(ap_and_channel.first); |
| 281 std::unique_ptr<PrimaryInstallDetails> details( | 281 std::unique_ptr<PrimaryInstallDetails> details( |
| 282 MakeProductDetails(test_data().path)); | 282 MakeProductDetails(test_data().path)); |
| 283 if (kInstallModes[test_data().index].channel_strategy == | 283 if (kInstallModes[test_data().index].channel_strategy == |
| 284 ChannelStrategy::ADDITIONAL_PARAMETERS) { | 284 ChannelStrategy::ADDITIONAL_PARAMETERS) { |
| 285 EXPECT_THAT(details->channel(), StrEq(ap_and_channel.second)); | 285 EXPECT_THAT(details->channel(), StrEq(ap_and_channel.second)); |
| 286 EXPECT_THAT(details->update_ap(), StrEq(ap_and_channel.first)); |
| 286 } else { | 287 } else { |
| 287 // "ap" is ignored for this mode. | 288 // "ap" is ignored for this mode. |
| 288 EXPECT_THAT(details->channel(), StrEq(test_data().channel)); | 289 EXPECT_THAT(details->channel(), StrEq(test_data().channel)); |
| 289 } | 290 } |
| 290 } | 291 } |
| 291 } | 292 } |
| 292 | 293 |
| 293 INSTANTIATE_TEST_CASE_P(All, | 294 INSTANTIATE_TEST_CASE_P(All, |
| 294 MakeProductDetailsTest, | 295 MakeProductDetailsTest, |
| 295 testing::ValuesIn(kTestData)); | 296 testing::ValuesIn(kTestData)); |
| 296 | 297 |
| 297 } // namespace install_static | 298 } // namespace install_static |
| OLD | NEW |