def test_tag_absorb_permanent(self) -> None:
        """Test that a tag can absorb another tag."""
        tag = Tag(name="test").save()
        Tag(name="old_tag_1", produces=["tag_prod1"], count=10).save()
        Tag(name="old_tag_2", replaces=["typod_tag"], produces=["tag_prod2"]).save()
        merge_count = tag.absorb(["old_tag_1", "old_tag_2"], permanent=True)

        self.assertEqual(merge_count, 2)
        self.assertEqual(tag.count, 10)
        self.assertEqual(
            sorted(tag.replaces), sorted(["old_tag_1", "old_tag_2", "typod_tag"])
        )
        self.assertEqual(sorted(tag.produces), sorted(["tag_prod1", "tag_prod2"]))

        self.assertIsNone(Tag.find(name="old_tag_1"))
        self.assertIsNone(Tag.find(name="old_tag_1"))
        self.assertIsNotNone(Tag.find(name="test"))
Test that a tag can absorb another tag.
tests/schemas/tag.py