Lines Matching refs:attempter_
227 FakeSystemState::Get()->set_update_attempter(&attempter_); in SetUp()
237 attempter_.set_forced_update_pending_callback( in SetUp()
240 attempter_.Init(); in SetUp()
242 EXPECT_EQ(0, attempter_.http_response_code_); in SetUp()
243 EXPECT_EQ(UpdateStatus::IDLE, attempter_.status_); in SetUp()
244 EXPECT_EQ(0.0, attempter_.download_progress_); in SetUp()
245 EXPECT_EQ(0, attempter_.last_checked_time_); in SetUp()
246 EXPECT_EQ("0.0.0.0", attempter_.new_version_); in SetUp()
247 EXPECT_EQ(0ULL, attempter_.new_payload_size_); in SetUp()
249 attempter_.processor_.reset(processor_); // Transfers ownership. in SetUp()
316 UpdateAttempterUnderTest attempter_; member in chromeos_update_engine::UpdateAttempterTest
342 attempter_.status_ = cfu_params_.status; in TestCheckForUpdate()
351 attempter_.CheckForUpdate( in TestCheckForUpdate()
356 attempter_.forced_app_version()); in TestCheckForUpdate()
358 attempter_.forced_omaha_url()); in TestCheckForUpdate()
360 attempter_.WasScheduleUpdatesCalled()); in TestCheckForUpdate()
365 attempter_.DisableScheduleUpdates(); in TestProcessingDone()
366 attempter_.is_install_ = pd_params_.is_install; in TestProcessingDone()
367 attempter_.status_ = pd_params_.status; in TestProcessingDone()
368 attempter_.omaha_request_params_->set_dlc_apps_params( in TestProcessingDone()
386 attempter_.ProcessingDone(pd_params_.processor, pd_params_.code); in TestProcessingDone()
389 EXPECT_EQ(pd_params_.kExpectedIsInstall, attempter_.is_install_); in TestProcessingDone()
391 attempter_.WasScheduleUpdatesCalled()); in TestProcessingDone()
392 EXPECT_EQ(pd_params_.expected_exit_status, attempter_.status_); in TestProcessingDone()
403 EXPECT_NE(UpdateStatus::UPDATED_NEED_REBOOT, attempter_.status()); in SessionIdTestChange()
404 const auto old_session_id = attempter_.session_id_; in SessionIdTestChange()
405 attempter_.Update({}); in SessionIdTestChange()
406 EXPECT_NE(old_session_id, attempter_.session_id_); in SessionIdTestChange()
421 attempter_.DisableScheduleUpdates(); in SessionIdTestEnforceEmptyStrPingOmaha()
422 attempter_.status_ = UpdateStatus::UPDATED_NEED_REBOOT; in SessionIdTestEnforceEmptyStrPingOmaha()
423 const auto old_session_id = attempter_.session_id_; in SessionIdTestEnforceEmptyStrPingOmaha()
432 attempter_.PingOmaha(); in SessionIdTestEnforceEmptyStrPingOmaha()
433 EXPECT_EQ(old_session_id, attempter_.session_id_); in SessionIdTestEnforceEmptyStrPingOmaha()
434 EXPECT_EQ(UpdateStatus::UPDATED_NEED_REBOOT, attempter_.status_); in SessionIdTestEnforceEmptyStrPingOmaha()
457 attempter_.BuildUpdateActions(false); in SessionIdTestConsistencyInUpdateFlow()
484 attempter_.BuildUpdateActions(false); in SessionIdTestInDownloadAction()
486 EXPECT_EQ(attempter_.session_id_, header_value); in SessionIdTestInDownloadAction()
502 attempter_.ActionCompleted(nullptr, &action, ErrorCode::kSuccess); in TEST_F()
504 EXPECT_EQ(UpdateStatus::FINALIZING, attempter_.status()); in TEST_F()
505 EXPECT_EQ(0.0, attempter_.download_progress_); in TEST_F()
506 ASSERT_EQ(nullptr, attempter_.error_event_.get()); in TEST_F()
512 attempter_.status_ = UpdateStatus::DOWNLOADING; in TEST_F()
513 attempter_.ActionCompleted(nullptr, &action, ErrorCode::kError); in TEST_F()
514 ASSERT_NE(nullptr, attempter_.error_event_.get()); in TEST_F()
530 EXPECT_EQ(0.0, attempter_.download_progress_); in TEST_F()
533 attempter_.new_payload_size_ = bytes_total; in TEST_F()
545 attempter_.AddObserver(&observer); in TEST_F()
546 attempter_.BytesReceived(bytes_progressed_1, bytes_received_1, bytes_total); in TEST_F()
547 EXPECT_EQ(progress_1, attempter_.download_progress_); in TEST_F()
551 attempter_.BytesReceived(bytes_progressed_2, bytes_received_2, bytes_total); in TEST_F()
552 EXPECT_EQ(progress_2, attempter_.download_progress_); in TEST_F()
561 attempter_.status_ = UpdateStatus::CHECKING_FOR_UPDATE; in TEST_F()
564 attempter_.new_payload_size_ = bytes_total; in TEST_F()
565 EXPECT_EQ(0.0, attempter_.download_progress_); in TEST_F()
571 attempter_.AddObserver(&observer); in TEST_F()
572 attempter_.BytesReceived(bytes_progressed, bytes_received, bytes_total); in TEST_F()
573 EXPECT_EQ(UpdateStatus::DOWNLOADING, attempter_.status_); in TEST_F()
582 attempter_.status_ = UpdateStatus::DOWNLOADING; in TEST_F()
583 attempter_.new_payload_size_ = bytes_total; in TEST_F()
584 EXPECT_EQ(0.0, attempter_.download_progress_); in TEST_F()
591 attempter_.AddObserver(&observer); in TEST_F()
592 attempter_.BytesReceived(bytes_progressed, bytes_received, bytes_total); in TEST_F()
593 EXPECT_EQ(1.0, attempter_.download_progress_); in TEST_F()
605 attempter_.ActionCompleted(nullptr, &action, ErrorCode::kSuccess); in TEST_F()
607 EXPECT_EQ(500, attempter_.http_response_code()); in TEST_F()
608 EXPECT_EQ(UpdateStatus::IDLE, attempter_.status()); in TEST_F()
609 EXPECT_EQ(234U, attempter_.server_dictated_poll_interval_); in TEST_F()
610 ASSERT_TRUE(attempter_.error_event_.get() == nullptr); in TEST_F()
618 attempter_.Init(); in TEST_F()
619 EXPECT_EQ(UpdateStatus::UPDATED_NEED_REBOOT, attempter_.status()); in TEST_F()
651 attempter_.omaha_request_params_->set_delta_okay(true); in TEST_F()
652 attempter_.DisableDeltaUpdateIfNeeded(); in TEST_F()
653 EXPECT_TRUE(attempter_.omaha_request_params_->delta_okay()); in TEST_F()
656 attempter_.DisableDeltaUpdateIfNeeded(); in TEST_F()
657 EXPECT_TRUE(attempter_.omaha_request_params_->delta_okay()); in TEST_F()
660 attempter_.DisableDeltaUpdateIfNeeded(); in TEST_F()
661 EXPECT_FALSE(attempter_.omaha_request_params_->delta_okay()); in TEST_F()
662 attempter_.DisableDeltaUpdateIfNeeded(); in TEST_F()
663 EXPECT_FALSE(attempter_.omaha_request_params_->delta_okay()); in TEST_F()
667 attempter_.MarkDeltaUpdateFailure(); in TEST_F()
670 attempter_.MarkDeltaUpdateFailure(); in TEST_F()
675 attempter_.MarkDeltaUpdateFailure(); in TEST_F()
681 attempter_.MarkDeltaUpdateFailure(); in TEST_F()
697 attempter_.ScheduleErrorEventAction(); in TEST_F()
709 attempter_.error_event_.reset(new OmahaEvent( in TEST_F()
711 attempter_.ScheduleErrorEventAction(); in TEST_F()
712 EXPECT_EQ(UpdateStatus::REPORTING_ERROR_EVENT, attempter_.status()); in TEST_F()
741 attempter_.set_http_response_code(200); in UpdateTestStart()
749 attempter_.policy_provider_.reset( in UpdateTestStart()
762 attempter_.Update({}); in UpdateTestStart()
769 EXPECT_EQ(0, attempter_.http_response_code()); in UpdateTestVerify()
770 EXPECT_EQ(&attempter_, processor_->delegate()); in UpdateTestVerify()
771 EXPECT_EQ(UpdateStatus::CHECKING_FOR_UPDATE, attempter_.status()); in UpdateTestVerify()
792 attempter_.policy_provider_.reset( in RollbackTestStart()
820 EXPECT_TRUE(attempter_.Rollback(true)); in RollbackTestStart()
825 EXPECT_FALSE(attempter_.Rollback(true)); in RollbackTestStart()
832 EXPECT_EQ(&attempter_, processor_->delegate()); in RollbackTestVerify()
833 EXPECT_EQ(UpdateStatus::ATTEMPTING_ROLLBACK, attempter_.status()); in RollbackTestVerify()
834 EXPECT_EQ(0U, attempter_.install_plan_->partitions.size()); in RollbackTestVerify()
835 EXPECT_EQ(attempter_.install_plan_->powerwash_required, true); in RollbackTestVerify()
876 attempter_.PingOmaha(); in PingOmahaTestStart()
881 EXPECT_FALSE(attempter_.waiting_for_scheduled_check_); in TEST_F()
882 EXPECT_FALSE(attempter_.WasScheduleUpdatesCalled()); in TEST_F()
885 attempter_.DisableScheduleUpdates(); in TEST_F()
890 EXPECT_EQ(UpdateStatus::UPDATED_NEED_REBOOT, attempter_.status()); in TEST_F()
891 EXPECT_TRUE(attempter_.WasScheduleUpdatesCalled()); in TEST_F()
897 attempter_.CreatePendingErrorEvent(&action, kCode); in TEST_F()
898 ASSERT_NE(nullptr, attempter_.error_event_.get()); in TEST_F()
899 EXPECT_EQ(OmahaEvent::kTypeUpdateComplete, attempter_.error_event_->type); in TEST_F()
900 EXPECT_EQ(OmahaEvent::kResultError, attempter_.error_event_->result); in TEST_F()
904 attempter_.error_event_->error_code); in TEST_F()
908 attempter_.install_plan_.reset(new InstallPlan); in TEST_F()
909 attempter_.install_plan_->is_resume = true; in TEST_F()
912 attempter_.CreatePendingErrorEvent(&action, kCode); in TEST_F()
913 ASSERT_NE(nullptr, attempter_.error_event_.get()); in TEST_F()
914 EXPECT_EQ(OmahaEvent::kTypeUpdateComplete, attempter_.error_event_->type); in TEST_F()
915 EXPECT_EQ(OmahaEvent::kResultError, attempter_.error_event_->result); in TEST_F()
920 attempter_.error_event_->error_code); in TEST_F()
928 attempter_.UpdateEngineStarted(); in TEST_F()
936 attempter_.UpdateEngineStarted(); in TEST_F()
945 attempter_.UpdateEngineStarted(); in TEST_F()
962 attempter_.Update({}); in P2PNotEnabledStart()
984 attempter_.Update({}); in P2PEnabledStartingFailsStart()
1007 attempter_.Update({}); in P2PEnabledHousekeepingFailsStart()
1029 attempter_.Update({}); in P2PEnabledStart()
1052 attempter_.Update({.interactive = true}); in P2PEnabledInteractiveStart()
1079 attempter_.policy_provider_.reset( in ReadScatterFactorFromPolicyTestStart()
1082 attempter_.Update({}); in ReadScatterFactorFromPolicyTestStart()
1083 EXPECT_EQ(scatter_factor_in_seconds, attempter_.scatter_factor_.InSeconds()); in ReadScatterFactorFromPolicyTestStart()
1115 attempter_.policy_provider_.reset( in DecrementUpdateCheckCountTestStart()
1118 attempter_.Update({}); in DecrementUpdateCheckCountTestStart()
1119 EXPECT_EQ(scatter_factor_in_seconds, attempter_.scatter_factor_.InSeconds()); in DecrementUpdateCheckCountTestStart()
1129 attempter_.omaha_request_params_->update_check_count_wait_enabled()); in DecrementUpdateCheckCountTestStart()
1134 attempter_.Update({}); in DecrementUpdateCheckCountTestStart()
1174 attempter_.policy_provider_.reset( in NoScatteringDoneDuringManualUpdateTestStart()
1178 attempter_.Update({.interactive = true}); in NoScatteringDoneDuringManualUpdateTestStart()
1179 EXPECT_EQ(scatter_factor_in_seconds, attempter_.scatter_factor_.InSeconds()); in NoScatteringDoneDuringManualUpdateTestStart()
1184 attempter_.omaha_request_params_->wall_clock_based_wait_enabled()); in NoScatteringDoneDuringManualUpdateTestStart()
1186 EXPECT_EQ(0, attempter_.omaha_request_params_->waiting_period().InSeconds()); in NoScatteringDoneDuringManualUpdateTestStart()
1188 attempter_.omaha_request_params_->update_check_count_wait_enabled()); in NoScatteringDoneDuringManualUpdateTestStart()
1199 attempter_.scatter_factor_ = TimeDelta::FromSeconds(20); in SetUpStagingTest()
1207 attempter_.policy_provider_.reset( in SetUpStagingTest()
1225 attempter_.Update({}); in StagingSetsPrefsAndTurnsOffScatteringStart()
1238 attempter_.omaha_request_params_->update_check_count_wait_enabled()); in StagingSetsPrefsAndTurnsOffScatteringStart()
1240 attempter_.omaha_request_params_->wall_clock_based_wait_enabled()); in StagingSetsPrefsAndTurnsOffScatteringStart()
1242 attempter_.omaha_request_params_->waiting_period().InDays()); in StagingSetsPrefsAndTurnsOffScatteringStart()
1244 EXPECT_EQ(waiting_time_days, attempter_.staging_wait_time_.InDays()); in StagingSetsPrefsAndTurnsOffScatteringStart()
1245 EXPECT_EQ(kValidStagingSchedule, attempter_.staging_schedule_); in StagingSetsPrefsAndTurnsOffScatteringStart()
1247 EXPECT_EQ(0, attempter_.scatter_factor_.InSeconds()); in StagingSetsPrefsAndTurnsOffScatteringStart()
1259 EXPECT_EQ(0, attempter_.omaha_request_params_->waiting_period().InDays()); in CheckStagingOff()
1260 EXPECT_EQ(attempter_.omaha_request_params_->waiting_period(), in CheckStagingOff()
1261 attempter_.staging_wait_time_); in CheckStagingOff()
1263 attempter_.omaha_request_params_->update_check_count_wait_enabled()); in CheckStagingOff()
1265 attempter_.omaha_request_params_->wall_clock_based_wait_enabled()); in CheckStagingOff()
1267 EXPECT_EQ(0, attempter_.scatter_factor_.InSeconds()); in CheckStagingOff()
1282 attempter_.Update({.interactive = true}); in StagingOffIfInteractiveStart()
1301 attempter_.Update({.interactive = true}); in StagingOffIfOobeStart()
1315 EXPECT_TRUE(attempter_.CheckAndReportDailyMetrics()); in TEST_F()
1317 EXPECT_FALSE(attempter_.CheckAndReportDailyMetrics()); in TEST_F()
1321 EXPECT_FALSE(attempter_.CheckAndReportDailyMetrics()); in TEST_F()
1326 EXPECT_FALSE(attempter_.CheckAndReportDailyMetrics()); in TEST_F()
1330 EXPECT_TRUE(attempter_.CheckAndReportDailyMetrics()); in TEST_F()
1333 EXPECT_FALSE(attempter_.CheckAndReportDailyMetrics()); in TEST_F()
1337 EXPECT_FALSE(attempter_.CheckAndReportDailyMetrics()); in TEST_F()
1339 EXPECT_TRUE(attempter_.CheckAndReportDailyMetrics()); in TEST_F()
1340 EXPECT_FALSE(attempter_.CheckAndReportDailyMetrics()); in TEST_F()
1344 EXPECT_FALSE(attempter_.CheckAndReportDailyMetrics()); in TEST_F()
1346 EXPECT_TRUE(attempter_.CheckAndReportDailyMetrics()); in TEST_F()
1347 EXPECT_FALSE(attempter_.CheckAndReportDailyMetrics()); in TEST_F()
1354 EXPECT_TRUE(attempter_.CheckAndReportDailyMetrics()); in TEST_F()
1355 EXPECT_FALSE(attempter_.CheckAndReportDailyMetrics()); in TEST_F()
1360 EXPECT_FALSE(attempter_.CheckAndReportDailyMetrics()); in TEST_F()
1362 EXPECT_TRUE(attempter_.CheckAndReportDailyMetrics()); in TEST_F()
1363 EXPECT_FALSE(attempter_.CheckAndReportDailyMetrics()); in TEST_F()
1368 attempter_.Init(); in TEST_F()
1371 EXPECT_FALSE(attempter_.GetBootTimeAtUpdate(&boot_time)); in TEST_F()
1373 attempter_.WriteUpdateCompletedMarker(); in TEST_F()
1375 EXPECT_TRUE(attempter_.GetBootTimeAtUpdate(&boot_time)); in TEST_F()
1381 EXPECT_TRUE(attempter_.IsAnyUpdateSourceAllowed()); in TEST_F()
1387 EXPECT_TRUE(attempter_.IsAnyUpdateSourceAllowed()); in TEST_F()
1393 EXPECT_FALSE(attempter_.IsAnyUpdateSourceAllowed()); in TEST_F()
1401 attempter_.status_ = status; in TEST_F()
1403 EXPECT_FALSE(attempter_.CheckForInstall({}, "")); in TEST_F()
1558 attempter_.set_forced_update_pending_callback(nullptr); in TEST_F()
1572 attempter_.set_forced_update_pending_callback(nullptr); in TEST_F()
1586 attempter_.CheckForInstall({}, "autest"); in TEST_F()
1587 EXPECT_EQ(constants::kOmahaDefaultAUTestURL, attempter_.forced_omaha_url()); in TEST_F()
1589 attempter_.CheckForInstall({}, "autest-scheduled"); in TEST_F()
1590 EXPECT_EQ(constants::kOmahaDefaultAUTestURL, attempter_.forced_omaha_url()); in TEST_F()
1592 attempter_.CheckForInstall({}, "http://omaha.phishing"); in TEST_F()
1593 EXPECT_EQ("", attempter_.forced_omaha_url()); in TEST_F()
1597 attempter_.CheckForInstall({}, "http://foo.bar"); in TEST_F()
1598 attempter_.status_ = UpdateStatus::DOWNLOADING; in TEST_F()
1599 EXPECT_TRUE(attempter_.is_install_); in TEST_F()
1600 attempter_.ProcessingDone(nullptr, ErrorCode::kSuccess); in TEST_F()
1602 attempter_.GetStatus(&status); in TEST_F()
1608 attempter_.is_install_ = true; in TEST_F()
1609 attempter_.Rollback(false); in TEST_F()
1610 EXPECT_FALSE(attempter_.is_install_); in TEST_F()
1614 attempter_.is_install_ = true; in TEST_F()
1615 attempter_.CheckForUpdate("", "", UpdateAttemptFlags::kNone); in TEST_F()
1616 EXPECT_FALSE(attempter_.is_install_); in TEST_F()
1621 attempter_.CalculateUpdateParams({.target_version_prefix = "1234"}); in TEST_F()
1625 attempter_.CalculateUpdateParams({}); in TEST_F()
1633 attempter_.CalculateUpdateParams({.lts_tag = "hint"}); in TEST_F()
1636 attempter_.CalculateUpdateParams({}); in TEST_F()
1641 attempter_.CalculateUpdateParams({ in TEST_F()
1651 attempter_.CalculateUpdateParams({ in TEST_F()
1665 attempter_.CalculateUpdateParams({ in TEST_F()
1676 attempter_.CalculateUpdateParams({ in TEST_F()
1692 attempter_.ActionCompleted( in TEST_F()
1696 attempter_.GetStatus(&status); in TEST_F()
1698 EXPECT_TRUE(attempter_.install_plan_); in TEST_F()
1699 EXPECT_EQ(attempter_.install_plan_->version, status.new_version); in TEST_F()
1700 EXPECT_EQ(attempter_.install_plan_->payloads[0].size, in TEST_F()
1705 EXPECT_TRUE(nullptr != attempter_.error_event_); in TEST_F()
1706 EXPECT_EQ(OmahaEvent::kTypeUpdateComplete, attempter_.error_event_->type); in TEST_F()
1707 EXPECT_EQ(OmahaEvent::kResultUpdateDeferred, attempter_.error_event_->result); in TEST_F()
1711 EXPECT_EQ(expected_code, attempter_.error_event_->error_code); in TEST_F()
1713 attempter_.ProcessingDone(nullptr, ErrorCode::kOmahaUpdateDeferredPerPolicy); in TEST_F()
1717 attempter_.GetStatus(&status); in TEST_F()
1727 EXPECT_FALSE(attempter_.IsBusyOrUpdateScheduled()); in TEST_F()
1729 attempter_.status_ = UpdateStatus::UPDATE_AVAILABLE; in TEST_F()
1730 EXPECT_TRUE(attempter_.IsBusyOrUpdateScheduled()); in TEST_F()
1734 attempter_.SetUpdateAttemptFlags(UpdateAttemptFlags::kFlagRestrictDownload); in TEST_F()
1737 attempter_.OnUpdateScheduled(EvalStatus::kSucceeded, params); in TEST_F()
1740 attempter_.GetCurrentUpdateAttemptFlags()); in TEST_F()
1746 attempter_.OnUpdateScheduled(EvalStatus::kSucceeded, params); in TEST_F()
1753 attempter_.OnUpdateScheduled(EvalStatus::kSucceeded, params); in TEST_F()
1758 attempter_.SetUpdateAttemptFlags(UpdateAttemptFlags::kFlagRestrictDownload); in TEST_F()
1760 attempter_.CheckForUpdate("", "", UpdateAttemptFlags::kNone); in TEST_F()
1762 attempter_.GetCurrentUpdateAttemptFlags()); in TEST_F()
1766 attempter_.SetUpdateAttemptFlags(UpdateAttemptFlags::kNone); in TEST_F()
1770 attempter_.CheckForUpdate("", in TEST_F()
1775 attempter_.GetCurrentUpdateAttemptFlags()); in TEST_F()
1796 attempter_.policy_provider_ = std::move(mock_policy_provider); in ResetRollbackHappenedStart()
1797 attempter_.Update({}); in ResetRollbackHappenedStart()
1832 attempter_.install_plan_.reset(new InstallPlan); in TEST_F()
1833 attempter_.install_plan_->is_rollback = true; in TEST_F()
1838 attempter_.ProcessingDone(nullptr, ErrorCode::kSuccess); in TEST_F()
1842 attempter_.install_plan_.reset(new InstallPlan); in TEST_F()
1843 attempter_.install_plan_->is_rollback = false; in TEST_F()
1848 attempter_.ProcessingDone(nullptr, ErrorCode::kSuccess); in TEST_F()
1852 attempter_.install_plan_.reset(new InstallPlan); in TEST_F()
1853 attempter_.install_plan_->is_rollback = true; in TEST_F()
1854 attempter_.install_plan_->version = kRollbackVersion; in TEST_F()
1859 attempter_.ProcessingDone(nullptr, ErrorCode::kSuccess); in TEST_F()
1863 attempter_.install_plan_.reset(new InstallPlan); in TEST_F()
1864 attempter_.install_plan_->is_rollback = false; in TEST_F()
1865 attempter_.install_plan_->version = kRollbackVersion; in TEST_F()
1870 attempter_.ProcessingDone(nullptr, ErrorCode::kSuccess); in TEST_F()
1874 attempter_.install_plan_.reset(new InstallPlan); in TEST_F()
1875 attempter_.install_plan_->is_rollback = true; in TEST_F()
1876 attempter_.install_plan_->version = kRollbackVersion; in TEST_F()
1882 attempter_.CreatePendingErrorEvent(&action, ErrorCode::kRollbackNotPossible); in TEST_F()
1883 attempter_.ProcessingDone(nullptr, ErrorCode::kRollbackNotPossible); in TEST_F()
1887 attempter_.install_plan_.reset(new InstallPlan); in TEST_F()
1888 attempter_.install_plan_->is_rollback = false; in TEST_F()
1889 attempter_.install_plan_->version = kRollbackVersion; in TEST_F()
1895 attempter_.CreatePendingErrorEvent(&action, ErrorCode::kRollbackNotPossible); in TEST_F()
1896 attempter_.ProcessingDone(nullptr, ErrorCode::kRollbackNotPossible); in TEST_F()
1903 attempter_.ProcessingDone(nullptr, ErrorCode::kOmahaUpdateDeferredPerPolicy); in TEST_F()
1916 attempter_.ProcessingDone(nullptr, ErrorCode::kSuccess); in TEST_F()
1941 attempter_.ProcessingDone(nullptr, ErrorCode::kSuccess); in TEST_F()
1966 attempter_.ProcessingDone(nullptr, ErrorCode::kSuccess); in TEST_F()
2070 attempter_.error_event_.reset(new OmahaEvent(OmahaEvent::kTypeUpdateComplete, in TEST_F()
2094 attempter_.error_event_.reset(new OmahaEvent(OmahaEvent::kTypeUpdateComplete, in TEST_F()
2113 attempter_.CalculateUpdateParams({.quick_fix_build_token = "token"}); in TEST_F()
2117 attempter_.CalculateUpdateParams({}); in TEST_F()
2125 EXPECT_TRUE(attempter_.ScheduleUpdates()); in TEST_F()
2128 EXPECT_FALSE(attempter_.ScheduleUpdates()); in TEST_F()
2129 EXPECT_FALSE(attempter_.ScheduleUpdates()); in TEST_F()
2130 EXPECT_FALSE(attempter_.ScheduleUpdates()); in TEST_F()
2140 attempter_.SetWaitingForScheduledCheck(true); in TestOnUpdateScheduled()
2141 attempter_.DisableUpdate(); in TestOnUpdateScheduled()
2142 attempter_.DisableScheduleUpdates(); in TestOnUpdateScheduled()
2145 attempter_.OnUpdateScheduled(ous_params_.status, ous_params_.params); in TestOnUpdateScheduled()
2148 EXPECT_EQ(ous_params_.exit_status, attempter_.status()); in TestOnUpdateScheduled()
2150 attempter_.WasScheduleUpdatesCalled()); in TestOnUpdateScheduled()
2151 EXPECT_EQ(ous_params_.should_update_be_called, attempter_.WasUpdateCalled()); in TestOnUpdateScheduled()
2209 attempter_.GetStatus(&status); in TEST_F()
2214 attempter_.install_plan_.reset(new InstallPlan); in TEST_F()
2215 attempter_.install_plan_->is_rollback = false; in TEST_F()
2218 attempter_.GetStatus(&status); in TEST_F()
2223 attempter_.install_plan_.reset(new InstallPlan); in TEST_F()
2224 attempter_.install_plan_->is_rollback = true; in TEST_F()
2227 attempter_.GetStatus(&status); in TEST_F()
2233 attempter_.GetStatus(&status); in TEST_F()
2238 attempter_.install_plan_.reset(new InstallPlan); in TEST_F()
2239 attempter_.install_plan_->powerwash_required = true; in TEST_F()
2242 attempter_.GetStatus(&status); in TEST_F()
2247 attempter_.install_plan_.reset(new InstallPlan); in TEST_F()
2248 attempter_.install_plan_->is_rollback = true; in TEST_F()
2251 attempter_.GetStatus(&status); in TEST_F()
2259 attempter_.GetStatus(&status); in TEST_F()
2267 attempter_.GetStatus(&status); in TEST_F()
2273 attempter_.GetStatus(&status); in TEST_F()
2279 attempter_.is_install_ = true; in TEST_F()
2280 attempter_.dlc_ids_ = {dlc_id}; in TEST_F()
2281 attempter_.CalculateDlcParams(); in TEST_F()
2305 attempter_.is_install_ = false; in TEST_F()
2306 attempter_.CalculateDlcParams(); in TEST_F()
2338 attempter_.is_install_ = false; in TEST_F()
2339 attempter_.CalculateDlcParams(); in TEST_F()
2370 attempter_.is_install_ = false; in TEST_F()
2371 attempter_.CalculateDlcParams(); in TEST_F()
2400 attempter_.dlc_ids_ = {dlc_id}; in TEST_F()
2401 attempter_.is_install_ = true; in TEST_F()
2402 attempter_.CalculateDlcParams(); in TEST_F()
2415 attempter_.SetDlcActiveValue(true, dlc_id); in TEST_F()
2433 attempter_.SetDlcActiveValue(false, dlc_id); in TEST_F()
2442 attempter_.omaha_request_params_->set_dlc_apps_params( in TEST_F()
2446 EXPECT_THAT(attempter_.GetSuccessfulDlcIds(), ElementsAre(dlc_2)); in TEST_F()
2462 attempter_.Init(); in TEST_F()
2463 attempter_.MoveToPrefs({key1, key2}); in TEST_F()