Skip to content

Refactor Pipeline Schedule specs to new CalculateNextRunServiceSpec

What does this MR do and why?

This MR resolves some follow-up items from Issue #333392 (closed)

  1. Specs were refactored to correct class from PipelineScheduleSpec to CalculateNextRunServiceSpec
  2. Additional tests for #match? for class CronParser
  3. Self-Hosted instances have their own default plan. Updated specs to reflect that.

Screenshots or screen recordings

No screenshots as this was mainly a refactor

How to set up and validate locally

Ensure PipelineScheduling still works.

  1. Schedule a new Pipeline
  2. Pipeline schedule's run_at should accurately reflect the next time it should run according to the cron passed in
  3. Changing the worker's cron via gitlab.yml's pipeline_schedule_worker config should affect pipeline schedule's run_at

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #333392 (closed)

Edited by Max Fan

Merge request reports