class NotesControllerTest < ActionController::TestCase
fixtures :users, :user_roles
class NotesControllerTest < ActionController::TestCase
fixtures :users, :user_roles
- create(:note_comment, :note => note, :author_id => users(:normal_user).id)
- create(:note_comment, :note => note, :author_id => users(:second_public_user).id)
+ create(:note_comment, :note => note, :author => users(:normal_user))
+ create(:note_comment, :note => note, :author => users(:second_public_user))
end
assert_difference "NoteComment.count", 1 do
assert_difference "ActionMailer::Base.deliveries.size", 2 do
end
assert_difference "NoteComment.count", 1 do
assert_difference "ActionMailer::Base.deliveries.size", 2 do
assert_select "time", :count => 1
assert_select "name", "Note: #{open_note.id}"
assert_select "desc", :count => 1
assert_select "time", :count => 1
assert_select "name", "Note: #{open_note.id}"
assert_select "desc", :count => 1
assert_select "extensions", :count => 1 do
assert_select "id", open_note.id.to_s
assert_select "url", note_url(open_note, :format => "gpx")
assert_select "extensions", :count => 1 do
assert_select "id", open_note.id.to_s
assert_select "url", note_url(open_note, :format => "gpx")