Commit 690c4259 authored by Lin Jen-Shin's avatar Lin Jen-Shin Committed by Nick Thomas

Prefer Time.zone.now to pair with Time.zone.name

`Time.now` is local time, yet `Time.zone.now` is application
configuration time. They can be different.
parent cb18dfea
......@@ -97,7 +97,7 @@ describe Ci::PipelineSchedule do
let(:cron_worker_next_run_at) do
Gitlab::Ci::CronParser.new(Settings.cron_jobs['pipeline_schedule_worker']['cron'], Time.zone.name)
.next_time_from(Time.now)
.next_time_from(Time.zone.now)
end
context 'when creates new pipeline schedule' do
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment