Guest User

Untitled

a guest
Apr 24th, 2018
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.39 KB | None | 0 0
  1. # Bug Repo: DummyDynamicScope should never be used for backref storage
  2.  
  3. require 'rubygems'
  4. require 'dm-core'
  5. require 'dm-validations'
  6.  
  7. nv = DataMapper::Validate::NumericValidator.new("field_name",{})
  8.  
  9. 10.times do # 5.times works
  10. nv.send(:validate_with, :integer, 0, [])
  11. [ :gt, :lt, :gte, :lte, :eq, :ne ].each do |validation_type|
  12. nv.send(:validate_with, validation_type, 0, [])
  13. end
  14. end
Add Comment
Please, Sign In to add comment