X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/a91e50d308edafa975588287179d0ffbad4f5bc9..5d0ea2879632a950405c40823503640cbec65e8f:/test/models/changeset_comment_test.rb diff --git a/test/models/changeset_comment_test.rb b/test/models/changeset_comment_test.rb index 8215ce129..5ef0c1d93 100644 --- a/test/models/changeset_comment_test.rb +++ b/test/models/changeset_comment_test.rb @@ -2,7 +2,7 @@ require "test_helper" class ChangesetCommentTest < ActiveSupport::TestCase - fixtures :changesets + fixtures :changesets, :users # validations def test_does_not_accept_invalid_author @@ -33,8 +33,9 @@ class ChangesetCommentTest < ActiveSupport::TestCase end def test_comments_of_changeset_count - create_list(:changeset_comment, 3, :changeset_id => changesets(:normal_user_closed_change).id) - assert_equal 3, Changeset.find(changesets(:normal_user_closed_change).id).comments.count + changeset = create(:changeset) + create_list(:changeset_comment, 3, :changeset_id => changeset.id) + assert_equal 3, Changeset.find(changeset.id).comments.count end def test_body_valid