Fix #4629: Tag renames/aliases should also modify pool descriptions.

This commit is contained in:
evazion
2022-01-15 20:30:51 -06:00
parent 33103f6dc4
commit 5bec0aa147
4 changed files with 19 additions and 7 deletions

View File

@@ -217,6 +217,15 @@ class TagAliasTest < ActiveSupport::TestCase
assert_equal("foo [[bbb]] bar", @wiki.reload.body)
end
should "rewrite links in pool descriptions to use the new tag" do
@pool = create(:pool, description: "foo [[aaa]] bar")
TagAlias.approve!(antecedent_name: "aaa", consequent_name: "bbb", approver: @admin)
perform_enqueued_jobs
assert_equal("foo [[bbb]] bar", @pool.reload.description)
end
end
context "when the tags have artist entries" do