I'm running some tests on my validations and I've hit a snag. I have a validated property declared as follows:
property :my_int, Integer, :nullable => false validates_is_number :my_int, :only_integer => true Normally I would test this by setting my_int to, say, 2.5 and calling valid?. The problem is that DM converts the value to an Integer before it calls valid?, so the result will be true, which is not what I expect. Is this by design? How would folks recommend testing (or not) in this situation? Thanks, Earle --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "DataMapper" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/datamapper?hl=en -~----------~----~----~----~------~----~------~--~---
