Details
-
Improvement
-
Status: Closed
-
Normal
-
Resolution: Fixed
-
None
-
None
-
None
-
Platform 223 - 2019 Follow-up
Description
Please build automated tests to verify that expected values for content blocks fields come out of the PageModel API.
Real world scenarios that should be tested can be found in the namespaces created for testing HSTTWO-4690, specifically in files
- hippo-site-toolkit/content-beans/src/test/resources/hcm-config/namespaces/contentbeanstest/dynamicbeanpage.yaml (the namespace definition) [1]
- hippo-site-toolkit/content-beans/src/test/resources/hcm-content/content/documents/contentbeanstest/dynamicbeanpagecontent.yaml (a sample document using those fields) [2]
Scenario 1: Old way of configuring content blocks
Cases:
- Missing the content-validators property in the namespace definition, see field "/contentblocks" in [1] and property "/contentbeanstest:contentblocks" in [2]
- Including the content-validators property, see field "/contentblocksWithValidator" in [1] and property "/contentbeanstest:contentblocksWithValidator" in [2]
Scenario 2: New way of configuring content blocks (via Essentials)
See field "/essentialsGeneratedContentblocks" in [1]
Cases:
- Content blocks using an already 'known' compound type, see property "/contentbeanstest:essentialsGeneratedContentblocks" in [2]
- Using an 'unknown' compound type, see property "/contentbeanstest:essentialsGeneratedContentblocks[2]" in [2]
The dynamic beans are generated in a lazy way, i.e. when requested via the object converter. In the context of this issue, a compound type is 'known' when it has been used in a field other than the content blocks field (e.g. in a top level field), and that field was requested before the content blocks field. Then the dynamic bean for the compound is already generated by the time the content blocks field is requested
Attachments
Issue Links
- is a result of
-
HSTTWO-4690 Dynamic beans support for content blocks doesn't generate method getContentBlocks for a contentblocks field added via essentials
- Closed
- relates to
-
CMS-12812 Fix error log in Runtime Beans when no corresponding supertype is found
- Closed