improved messages fixtures. Additional user fixture (for sending messages between...
[rails.git] / test / unit / message_test.rb
1 require File.dirname(__FILE__) + '/../test_helper'
2
3 class MessageTest < Test::Unit::TestCase
4   fixtures :messages
5
6   def test_check_empty_message_fails
7     message = Message.new
8     assert !message.valid?
9     assert message.errors.invalid?(:title)
10     assert message.errors.invalid?(:body)
11     assert message.errors.invalid?(:sent_on)
12     assert true, message.message_read
13   end
14   
15 end