diff --git a/scripts/pipeline/pre_merge_checks.rb b/scripts/pipeline/pre_merge_checks.rb index c588a0a6f7ed3a99eea235ad7ac231100f0131e9..06d4937cc00cd95985f58a4fd2b1d6ee77fb5500 100755 --- a/scripts/pipeline/pre_merge_checks.rb +++ b/scripts/pipeline/pre_merge_checks.rb @@ -16,7 +16,7 @@ class PreMergeChecks DEFAULT_API_ENDPOINT = "https://gitlab.com/api/v4" MERGE_TRAIN_REF_REGEX = %r{\Arefs/merge-requests/\d+/train\z} - PIPELINE_FRESHNESS_DEFAULT_THRESHOLD_IN_HOURS = 8 + PIPELINE_FRESHNESS_DEFAULT_THRESHOLD_IN_HOURS = 12 PIPELINE_FRESHNESS_STABLE_BRANCHES_THRESHOLD_IN_HOURS = 72 PREDICTIVE_PIPELINE_IDENTIFIER = 'predictive' REQUIRED_TIER_IDENTIFIER = 'tier:3' diff --git a/spec/scripts/pipeline/pre_merge_checks_spec.rb b/spec/scripts/pipeline/pre_merge_checks_spec.rb index 5267c76a8f41670e431212f51b3a6af1df381207..81993c9bc0b6857c42a15400bb196a75387bd272 100644 --- a/spec/scripts/pipeline/pre_merge_checks_spec.rb +++ b/spec/scripts/pipeline/pre_merge_checks_spec.rb @@ -233,15 +233,15 @@ def yield_pipelines(api_method, pipelines) end context 'and it is not fresh enough' do - let(:latest_mr_pipeline_created_at) { "2024-05-29T01:30:00 UTC" } + let(:latest_mr_pipeline_created_at) { "2024-05-28T21:30:00 UTC" } it 'returns a failed PreMergeChecksStatus' do expect(instance.execute).to be_a(described_class::PreMergeChecksStatus) expect(instance.execute).not_to be_success expect(instance.execute.message) .to include( - "Expected latest pipeline (#{latest_mr_pipeline_web_url}) to be created within the last 8 hours " \ - "(it was created 8.5 hours ago)!" + "Expected latest pipeline (#{latest_mr_pipeline_web_url}) to be created within the last 12 hours " \ + "(it was created 12.5 hours ago)!" ) end end