search for: 766da8a5

Displaying 1 result from an estimated 1 matches for "766da8a5".

2006 Mar 26
4
A unit test that should pass
Hi, I wonder why this unit test fails. The model : class Article < ActiveRecord::Base set_table_name "publish_articles" belongs_to :category validates_presence_of :title, :excerpt #snip end The test : def test_validate @article.title = nil @article.excerpt = nil assert !@article.save assert_equal 2, !@article.errors.count end !@article.errors.count returns