Even though RenderedItemTest currently passes without problems, there's actually several things wrong with it:
- The view mode configuration for users and comments is not in the expected format (it should be keyed by both datasource ID and bundle ID, not just the former, even if there is only one pseudo-bundle).
- There is a view mdoe setting for the "article" content type, but that content type doesn't even exist.
- Why is the "Comment" module even included?
Also, the code currently uses short array syntax, which I have otherwise avoided to add in the module, for consistency's sake. (Although at this point we probably could already be consistent the other way round, too.)
When fixing these issues, it would be good to also add tests for the processor's calculateDependencies() and onDependencyRemoval() methods, as introduced in #2574633: Properly react when a plugin's dependencies are removed (at least the latter). And to also maybe add tests for viewing comments and/or users, if we already have those modules included.
Comments
Comment #2
drunken monkeyHere is a WIP, which currently fails because the "teaser" view mode set for comments actually doesn't even exist – there's only "full" by default.
Comment #3
borisson_This makes sense; setting to NR for the bot.
Comment #6
drunken monkeyComment #7
drunken monkeyStill not perfect, I skimmed over the comment testing a bit, but still a large improvement, I'd say. (Part of this, namely the dependency testing, has been resolved in the meantime, though.)
Comment #8
borisson_Looks good!
Comment #9
borisson_Comment #11
drunken monkeyGood to hear, thanks for reviewing!
Committed.