Sha256: 443f13ad240feaaeeea04dad1b4a686ff6f8334be4faee753e987c3da390c821
Contents?: true
Size: 613 Bytes
Versions: 12
Compression:
Stored size: 613 Bytes
Contents
require 'test_helper' describe Fanforce::AppWorker do before do clean_dbs end it 'should enqueue a job' do Fanforce::AppWorker.enqueue('test', {name: 'caleb'}) assert Fanforce::AppWorker.iron_mq.queue('test').size == 1 end it 'should run an enqueued job' do Fanforce::AppWorker.enqueue('test', {name: 'caleb'}) processed_job = false Fanforce::AppWorker.run({'queue_id' => 'test'}) do |params| processed_job = true assert params[:name] == 'caleb' end assert processed_job == true assert Fanforce::AppWorker.iron_mq.queue('test').size == 0 end end
Version data entries
12 entries across 12 versions & 1 rubygems