Files
danbooru/test/unit/moderation_reports_test.rb
evazion 24cb920608 mod reports: include reported user and message in forum post.
Also fix it so that reports against dmails include the key in the dmail
link so that mods can view the reported dmail.
2020-02-03 04:52:12 -06:00

16 lines
427 B
Ruby

require 'test_helper'
class ModerationReportTest < ActiveSupport::TestCase
context "Moderation reports: " do
context "creating a moderation report" do
should "create a forum post" do
@dmail = create(:dmail)
@modreport = create(:moderation_report, model: @dmail, reason: "blah")
assert_equal(2, ForumPost.count)
assert_match(/blah/, ForumPost.last.body)
end
end
end
end