test/unit/validatable_test.rb in validatable-1.1.2 vs test/unit/validatable_test.rb in validatable-1.2.1

- old
+ new

@@ -1,23 +1,15 @@ require File.expand_path(File.dirname(__FILE__) + '/../test_helper') module Unit class ValidatableTest < Test::Unit::TestCase expect false do - validation = stub(:valid? => false, :should_validate? => true, :attribute => "attribute", :message => "message", :level => 1) + validation = stub(:valid? => false, :should_validate? => true, :attribute => "attribute", :message => "message", :level => 1, :run_after_validate => nil) klass = Class.new do include Validatable validations << validation end klass.new.valid? - end - - expect [:anything, :else] do - klass = Class.new do - include Validatable - include_validations_for :anything, :else - end - klass.send(:children_to_validate) end test "when validate is executed, then messages are added for each validation that fails" do klass = Class.new do include Validatable \ No newline at end of file