| When a blog category is renamed, or migrated from the legacy Blog space to Blog.Categories, the blog posts that are in this category are updated, but the category is moved to the end of the categories list of each post instead of keeping its position. Steps to reproduce
- Create a blog post in the categories News, Other and Personal (in this order)
- Rename the News category (through a page rename / move) to Announcements
- Edit the blog post
Expected: the categories are Announcements, Other, Personal Actual: the categories are Other, Personal, Announcements The order of the categories is user data (it is the order in which they are displayed for the post). Cause The old value is removed from the list and the new one is appended, instead of being replaced in place:
The current behaviour is pinned by CategoryRenameListenerTest#renamingACategoryUpdatesTheBlogPostsInIt and CategoryLocationMigrationTest#migrateMovesTheLegacyCategoriesToTheCategoriesSpace (BLOG-269). |