Sha256: 8ab8c8d0db0b5485a70c5aeb6d8f7d8b9ea744f23a824af8cb40388cc93b8b70

Contents?: true

Size: 357 Bytes

Versions: 8

Compression:

Stored size: 357 Bytes

Contents

require 'spec_helper'

describe Virtus::Attribute, '#rename' do
  subject { object.rename(:bar) }

  let(:object) { described_class.build(String, :name => :foo, :strict => true) }
  let(:other)  { described_class.build(String, :name => :bar, :strict => true) }

  its(:name) { should be(:bar) }

  it { should_not be(object) }
  it { should be_strict }
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
virtus-1.0.3 spec/unit/virtus/attribute/rename_spec.rb
virtus-1.0.2 spec/unit/virtus/attribute/rename_spec.rb
virtus-1.0.1 spec/unit/virtus/attribute/rename_spec.rb
virtus-1.0.0 spec/unit/virtus/attribute/rename_spec.rb
virtus-1.0.0.rc2 spec/unit/virtus/attribute/rename_spec.rb
virtus-1.0.0.rc1 spec/unit/virtus/attribute/rename_spec.rb
virtus-1.0.0.beta8 spec/unit/virtus/attribute/rename_spec.rb
virtus-1.0.0.beta7 spec/unit/virtus/attribute/rename_spec.rb