summaryrefslogtreecommitdiff
path: root/spec/sidekiq/cron
diff options
context:
space:
mode:
authorDosuken shinya <gitlab.shinyamaeda@gmail.com>2017-05-10 15:48:09 +0000
committerRémy Coutable <remy@rymai.me>2017-05-10 15:48:09 +0000
commit11759374698eb172c05e6a701d4ff7dc5f9d8251 (patch)
tree68707ee7f05bbe323146db9216f75c52e448e61f /spec/sidekiq/cron
parent8d58e10385f128084a4187effa07cd4d3535dcbc (diff)
downloadgitlab-ce-11759374698eb172c05e6a701d4ff7dc5f9d8251.tar.gz
Resolve "Update gem sidekiq-cron from 0.4.4 to 0.6.0 and rufus-scheduler from 3.1.10 to 3.4.0"
Diffstat (limited to 'spec/sidekiq/cron')
-rw-r--r--spec/sidekiq/cron/job_gem_dependency_spec.rb18
1 files changed, 18 insertions, 0 deletions
diff --git a/spec/sidekiq/cron/job_gem_dependency_spec.rb b/spec/sidekiq/cron/job_gem_dependency_spec.rb
new file mode 100644
index 00000000000..2e30cf025b0
--- /dev/null
+++ b/spec/sidekiq/cron/job_gem_dependency_spec.rb
@@ -0,0 +1,18 @@
+require 'spec_helper'
+
+describe Sidekiq::Cron::Job do
+ describe 'cron jobs' do
+ context 'when rufus-scheduler depends on ZoTime or EoTime' do
+ before do
+ described_class
+ .create(name: 'TestCronWorker',
+ cron: Settings.cron_jobs[:pipeline_schedule_worker]['cron'],
+ class: Settings.cron_jobs[:pipeline_schedule_worker]['job_class'])
+ end
+
+ it 'does not get "Rufus::Scheduler::ZoTime/EtOrbi::EoTime into an exact number"' do
+ expect { described_class.all.first.should_enque?(Time.now) }.not_to raise_error
+ end
+ end
+ end
+end