When I use a format validation with a value expected to be a string but when a integer is passed raises an error no implicit conversion of Integer into String
To Reproduce
require "dry-validation"
class ValidatorWithFormat < Dry::Validation::Contract
params do
required(:field).filled(format?: /a+/).value(:string)
end
end
validator = ValidatorWithFormat.new
puts "it fails" if validator.call({ "field" => 0 }).failure?
puts "it pass" if validator.call({ "field" => "a" }).success?
Describe the bug
When I use a format validation with a value expected to be a string but when a integer is passed raises an error
no implicit conversion of Integer into String
To Reproduce
Expected behavior
The validation must fail
My environment