Sha256: 73691f2ddde95ade49e560d6e2624397c49f36932778062943becc324c9d5fe8

Contents?: true

Size: 456 Bytes

Versions: 10

Compression:

Stored size: 456 Bytes

Contents

require 'spec_helper'

describe Virtus::Options, '#accepted_options' do
  subject { object.accepted_options }

  specify { object.should respond_to(:accepted_options) }

  let(:object) do
    Class.new do
      extend Virtus::DescendantsTracker
      extend Virtus::Options
    end
  end

  let(:options) { [ :width, :height ] }

  before { object.accept_options(*options) }

  it { should be_instance_of(Array) }
  it { should include(*options)     }
end

Version data entries

10 entries across 10 versions & 2 rubygems

Version Path
fragrant-0.0.5 vendor/bundle/ruby/1.9.1/gems/virtus-0.5.2/spec/unit/virtus/options/accepted_options_spec.rb
virtus-0.5.2 spec/unit/virtus/options/accepted_options_spec.rb
virtus-0.5.1 spec/unit/virtus/options/accepted_options_spec.rb
virtus-0.5.0 spec/unit/virtus/options/accepted_options_spec.rb
virtus-0.4.2 spec/unit/virtus/options/accepted_options_spec.rb
virtus-0.4.1 spec/unit/virtus/options/accepted_options_spec.rb
virtus-0.4.0 spec/unit/virtus/options/accepted_options_spec.rb
virtus-0.3.0 spec/unit/virtus/options/accepted_options_spec.rb
virtus-0.2.0 spec/unit/virtus/options/accepted_options_spec.rb
virtus-0.1.0 spec/unit/virtus/options/accepted_options_spec.rb