You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There is a slight difference in exception message while comparating String and Integer between TruffleRuby and MRI.
TruffleRuby: #<ArgumentError: comparison of String with Integer>
MRI: #<ArgumentError: comparison of String with 23 failed>
This difference in TruffleRuby causes 20 failing specs in dry-schema specs where there is the following expectation
expect { result }.to raise_error(ArgumentError, 'comparison of String with 23 failed')
Then error is:
expected ArgumentError with "comparison of String with 23 failed", got #<ArgumentError: comparison of String with Integer> with backtrace:
# ~/.gem/truffleruby/2.6.5/gems/dry-logic-1.0.6/lib/dry/logic/predicates.rb:104:in `>'
# ~/.gem/truffleruby/2.6.5/gems/dry-logic-1.0.6/lib/dry/logic/predicates.rb:104:in `gt?'
# ~/.gem/truffleruby/2.6.5/gems/dry-logic-1.0.6/lib/dry/logic/predicates.rb:108:in `lteq?'
# ~/.gem/truffleruby/2.6.5/gems/dry-logic-1.0.6/lib/dry/logic/rule/interface.rb:123:in `[]'
# ~/.gem/truffleruby/2.6.5/gems/dry-logic-1.0.6/lib/dry/logic/rule/interface.rb:123:in `call'
# ~/.gem/truffleruby/2.6.5/gems/dry-logic-1.0.6/lib/dry/logic/operations/key.rb:41:in `call'
# ~/.gem/truffleruby/2.6.5/gems/dry-logic-1.0.6/lib/dry/logic/operations/implication.rb:22:in `call'
# ./lib/dry/schema/rule_applier.rb:36:in `block in call'
# ./lib/dry/schema/rule_applier.rb:33:in `each'
# ./lib/dry/schema/rule_applier.rb:33:in `call'
# ./lib/dry/schema/processor_steps.rb:96:in `process_step'
# ./lib/dry/schema/processor_steps.rb:39:in `block in call'
# ./lib/dry/schema/processor_steps.rb:37:in `each'
# ./lib/dry/schema/processor_steps.rb:37:in `call'
# ./lib/dry/schema/processor.rb:88:in `block in call'
# ./lib/dry/schema/result.rb:37:in `new'
# ./lib/dry/schema/processor.rb:87:in `call'
# ./spec/support/predicates_integration.rb:7:in `result'
# ./spec/integration/schema/predicates/lteq_spec.rb:103:in `block (5 levels) in <top (required)>'
# ./spec/integration/schema/predicates/lteq_spec.rb:103:in `block (4 levels) in <top (required)>'
# ./spec/integration/schema/predicates/lteq_spec.rb:103:in `block (4 levels) in <top (required)>'
The text was updated successfully, but these errors were encountered:
deepj
changed the title
Comparation of String and Integer throws an exception with slightly different error message but MRI
Comparation of String and Integer throws an exception with slightly different error message but in MRI
Feb 28, 2020
There is a slight difference in exception message while comparating String and Integer between TruffleRuby and MRI.
TruffleRuby:
#<ArgumentError: comparison of String with Integer>
MRI:
#<ArgumentError: comparison of String with 23 failed>
This difference in TruffleRuby causes 20 failing specs in
dry-schema
specs where there is the following expectationThen error is:
The text was updated successfully, but these errors were encountered: