Sha256: f90bacc98f13334c1affae603f797bbef4ddd9568769d6fb586f30bf5bcad7e0

Contents?: true

Size: 374 Bytes

Versions: 26

Compression:

Stored size: 374 Bytes

Contents

require "dry-types"

describe "value coercion via dry-types" do
  before do
    module Test::Types
      include Dry::Types.module
    end

    class Test::Foo
      extend Dry::Initializer::Mixin

      param :foo, type: Test::Types::Coercible::String
    end
  end

  subject { Test::Foo.new :foo }

  it "coerces values" do
    expect(subject.foo).to eql "foo"
  end
end

Version data entries

26 entries across 26 versions & 1 rubygems

Version Path
dry-initializer-1.2.0 spec/value_coercion_via_dry_types_spec.rb
dry-initializer-1.1.3 spec/value_coercion_via_dry_types_spec.rb
dry-initializer-1.1.2 spec/value_coercion_via_dry_types_spec.rb
dry-initializer-1.1.1 spec/value_coercion_via_dry_types_spec.rb
dry-initializer-1.1.0 spec/value_coercion_via_dry_types_spec.rb
dry-initializer-1.0.0 spec/value_coercion_via_dry_types_spec.rb
dry-initializer-0.11.0 spec/value_coercion_via_dry_types_spec.rb
dry-initializer-0.10.2 spec/value_coercion_via_dry_types_spec.rb
dry-initializer-0.10.1 spec/value_coercion_via_dry_types_spec.rb
dry-initializer-0.10.0 spec/value_coercion_via_dry_types_spec.rb
dry-initializer-0.9.3 spec/value_coercion_via_dry_types_spec.rb
dry-initializer-0.9.2 spec/value_coercion_via_dry_types_spec.rb
dry-initializer-0.9.1 spec/value_coercion_via_dry_types_spec.rb
dry-initializer-0.9.0 spec/value_coercion_via_dry_types_spec.rb
dry-initializer-0.8.1 spec/value_coercion_via_dry_types_spec.rb
dry-initializer-0.8.0 spec/value_coercion_via_dry_types_spec.rb
dry-initializer-0.7.0 spec/dry/value_coercion_via_dry_types_spec.rb
dry-initializer-0.6.0 spec/dry/value_coercion_via_dry_types_spec.rb
dry-initializer-0.5.0 spec/dry/value_coercion_via_dry_types_spec.rb
dry-initializer-0.4.0 spec/dry/value_coercion_via_dry_types_spec.rb