Sha256: ebd45c9b998a9f766f9a1fa9b377b78fbf486967c9b596d2ab91367c202c77af
Contents?: true
Size: 639 Bytes
Versions: 14
Compression:
Stored size: 639 Bytes
Contents
# encoding: utf-8 require 'spec_helper' describe Axiom::Types::Object, '.coercion_method' do let(:object) { Class.new(described_class) } let(:coercion_method) { :to_object } context 'with no arguments' do subject { object.coercion_method } it { should be(coercion_method) } end context 'with a symbol' do subject { object.coercion_method(symbol) } let(:symbol) { :to_string } it_should_behave_like 'a command method' it 'sets the coercion_method' do expect { subject }.to change { object.coercion_method } .from(coercion_method).to(symbol) end end end
Version data entries
14 entries across 12 versions & 4 rubygems