Sha256: 597f169474370b3152807eed43b894af348ca821b4413773c4d44ed971120ac5
Contents?: true
Size: 661 Bytes
Versions: 13
Compression:
Stored size: 661 Bytes
Contents
require 'spec_helper' describe Services::Asyncable do describe '#perform' do it 'calls `call` with the correct args' do expect { AsyncService.new.perform 'test', pelle: 'fant' }.to raise_error(%w(test baz fant).to_json) # If the `call` method arguments contains kwargs and the last argument to `perform` is a Hash, # it's keys should be symbolized. The reason is that the arguments to `perform` are serialized to # the database before Sidekiq picks them up, i.e. symbol keys are converted to strings. expect { AsyncService.new.perform 'test', 'pelle' => 'fant' }.to raise_error(%w(test baz fant).to_json) end end end
Version data entries
13 entries across 13 versions & 1 rubygems