Sha256: 01426ac94a29e424f80916ce5f85209515fdfa0590fd5a5bc666169a6a159e2e

Contents?: true

Size: 291 Bytes

Versions: 6

Compression:

Stored size: 291 Bytes

Contents

require "spec_helper"

describe AttrExtras do
  it "mixes helpers into all Modules (and thus all Classes)" do
    mod = Module.new do
      pattr_initialize :name
    end

    klass = Class.new do
      include mod
    end

    _(klass.new("Hello").send(:name)).must_equal "Hello"
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
attr_extras-7.1.0 spec/attr_extras_spec.rb
attr_extras-7.0.0 spec/attr_extras_spec.rb
attr_extras-6.2.5 spec/attr_extras_spec.rb
attr_extras-6.2.4 spec/attr_extras_spec.rb
attr_extras-6.2.3 spec/attr_extras_spec.rb
attr_extras-6.2.2 spec/attr_extras_spec.rb