| When a list of blog posts is displayed outside of the blog of a post (e.g. on a category page or in the aggregated list of the default blog), the footer of each post shows "Posted in <blog>" with a link to its blog. This line is missing for the posts of a blog whose blog page is not the WebHome of its space (an "in-space" blog, i.e. a Space.Blog page holding the Blog.BlogClass object, which #getBlogDocument supports). Steps to reproduce
- Create a page MySpace.Blog with a Blog.BlogClass object, leaving its posts and categories locations empty.
- Create a blog post MySpace.Post1 and assign it to the category Blog.Categories.News.
- View the category page Blog.Categories.News.
Expected: the footer of the post says "Posted in" with a link to MySpace.Blog. Actual: there's no "Posted in" line (it is displayed for the posts of a whole-space blog such as OtherBlog.WebHome). Cause #displayEntryBlogLocation (Blog.BlogCode, BlogCode.xml:848-862) doesn't use the blog document: it computes the posts location of the post's blog (#getBlogPostsLocation) and links to <postsLocation>.WebHome, displaying the line only if that page holds a Blog.BlogClass object. For an in-space blog the posts location is MySpace and MySpace.WebHome is not a blog, so nothing is displayed. The same happens for a blog whose posts location is outside of the blog space. Found while writing the characterization tests of BLOG-269 (BlogLocationPageTest#displayEntryBlogLocationDisplaysNothingForAnInSpaceBlog pins the current behaviour). |