Sha256: 4c07f608228415e95bd16dd7080b4d926558a158b1c3cc5226a50e0a87a9f1c4
Contents?: true
Size: 359 Bytes
Versions: 8
Compression:
Stored size: 359 Bytes
Contents
describe "gem enhancement" do before do Dry::Initializer::Attribute.dispatchers << ->(string: false, **op) do op[:type] = proc(&:to_s) if string op end class Test::Foo extend Dry::Initializer param :bar, string: true end end it "works" do foo = Test::Foo.new(:BAZ) expect(foo.bar).to eq "BAZ" end end
Version data entries
8 entries across 8 versions & 1 rubygems