Re-enable skipped `Scheduler::ScheduleInfo` test.
This commit is contained in:
parent
8ee31d3c85
commit
d940166a89
|
@ -63,7 +63,7 @@ module Scheduler
|
|||
return if valid?
|
||||
|
||||
at = @klass.daily[:at] || 0
|
||||
today_begin = Time.now.midnight.to_i
|
||||
today_begin = Time.zone.now.midnight.to_i
|
||||
today_offset = DateTime.now.seconds_since_midnight
|
||||
|
||||
# If it's later today
|
||||
|
|
|
@ -82,9 +82,13 @@ describe Scheduler::ScheduleInfo do
|
|||
expect(@info.valid?).to eq(false)
|
||||
end
|
||||
|
||||
skip "will have a due date at the appropriate time if blank" do
|
||||
it "will have a due date at the appropriate time if blank" do
|
||||
expect(@info.next_run).to eq(nil)
|
||||
@info.schedule!
|
||||
|
||||
expect(JSON.parse($redis.get(@info.key))["next_run"])
|
||||
.to eq((Time.zone.now.midnight + 2.hours).to_i)
|
||||
|
||||
expect(@info.valid?).to eq(true)
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue