The ValidatesNumericalityTest from validations.rb is never run because it doesn't inherit Test::Unit::TestCase.

Fix:
- class ValidatesNumericalityTest
+ class ValidatesNumericalityTest < Test::Unit::TestCase

Unfortunately this shows that 2 of the tests fail:

  1) Failure:
test_validates_numericality_of_with_integer_only_and_nil_allowed(ValidatesNumericalityTest)
    [validations_test.rb:1072:in `valid!'
     validations_test.rb:1070:in `valid!'
validations_test.rb:1057:in `test_validates_numericality_of_with_integer_only_and_nil_allowed']:
"" not accepted as a number.
<false> is not true.

  2) Failure:
test_validates_numericality_of_with_nil_allowed(ValidatesNumericalityTest)
    [validations_test.rb:1072:in `valid!'
     validations_test.rb:1070:in `valid!'
validations_test.rb:1043:in `test_validates_numericality_of_with_nil_allowed']:
"" not accepted as a number.
<false> is not true.

_______________________________________________
Rails-core mailing list
Rails-core@lists.rubyonrails.org
http://lists.rubyonrails.org/mailman/listinfo/rails-core

Reply via email to