Sha256: 591636858b55fdf75573c391ec09afec6dd900f1eecc921249adb52c65de2283
Contents?: true
Size: 576 Bytes
Versions: 4
Compression:
Stored size: 576 Bytes
Contents
require 'sham/config/empty' describe Sham::Config::Empty do before(:all) do Object.send(:remove_const, :EmptyTester) if defined?(EmptyTester) class EmptyTester attr_accessor :id def initialize(options) self.id = options[:id] end end end let(:config){ subject.object(EmptyTester) } it 'passes an empty hash by default' do EmptyTester.should_receive(:new).with({}) config.options.sham end it 'allows passed options' do EmptyTester.should_receive(:new).with(:id => 1) config.options(:id => 1).sham end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
sham-2.0.0 | spec/lib/sham/config/empty_spec.rb |
sham-1.2.0 | spec/lib/sham/config/empty_spec.rb |
sham-1.1.0 | spec/lib/sham/config/empty_spec.rb |
sham-1.0.3 | spec/lib/sham/config/empty_spec.rb |