-
Type:
Story
-
Status: Closed
-
Priority:
Minor
-
Resolution: Completed
-
Affects Version/s: None
-
Component/s: Fragment Administration
-
Branch Version/s:7.2.x
-
Backported to Branch:Committed
-
Epic Link:
Context
When web developers are defining the configuration of a fragment using the required JSON format, it is easy for them to make accidental mistakes. The purpose of this story is to provide validation of the configuration definition providing accurate information about any errors.
Note: The FieldSet label should be optional and the field names must be unique.
Acceptance Criteria
1. Configuration validation with Fragment Toolkit with a valid configuration
- Given a fragment with a valid configuration,
- when the fragment is imported with the fragment toolkit,
- then the import succeeds
- and the configuration is imported along with the fragment code.
2. Configuration validation with Fragment Toolkit with an invalid configuration
- Given a fragment with an invalid configuration,
- when the fragment is imported with the fragment toolkit,
- then the import fails
- and an error message is show informing the developer of the error.
3. Configuration validation in Fragment Editor with an invalid configuration is previewed
- Given a fragment with an invalid configuration,
- when the fragment is previewed in the preview pane,
- then the preview pane shows an error message is show informing the developer of the error.
4. Configuration validation in Fragment Editor with an invalid configuration cannot be saved
- Given a fragment with an invalid configuration,
- when the fragment is saved with the fragment toolkit,
- then the save fails informing the user that there is an error**
Technical details
- It's recommended to use JSON schema to perform the validation
- is a dependency of
-
LPS-97642 Validate fragment configuration in Fragment Toolkit
-
- Closed
-
- Testing discovered
-
LPS-100735 FragmentsImporterImpl only validates the html and not the config of an imported fragment
- Closed
- links to