stable
Clone or download
Part of story #12187 configure workflow pre & post actions at target state level Improve front tests maintainability with Object Mother Pattern: - adding new data model attributes in tested components do not make tests to be updated (if not involved in test cases) - Attributes which are not useful for test case are not declared - Specific data model state (ex: workflow without configured field is a workflow with "field_id: null" and "is_used : 0") are declared in one single place (in factories declaration) DSL usage: - create('workflow') will create a new workflow with default attributes - create('workflow', {field_id: 2}) will do the same with "field_id: 2" - create('workflow', 'field_not_defined') will create a workflow with "field_id: null" and "is_used : 0" - createList('workflow', 2) will create 2 workflows Change-Id: I0ba88e5c177b43852e2e36c8101bd8f4bb54d626
Modified Files
Name | ||||
---|---|---|---|---|
M | plugins/tracker/www/scripts/workflow-transitions/src/api/rest-querier.spec.js | +2 | −2 | Go to diff View file |
M | plugins/tracker/www/scripts/workflow-transitions/src/components/BaseTrackerWorkflowTransitions.spec.js | +11 | −2 | Go to diff View file |
M | plugins/tracker/www/scripts/workflow-transitions/src/components/FirstConfigurationSections.spec.js | +2 | −4 | Go to diff View file |
M | plugins/tracker/www/scripts/workflow-transitions/src/components/TransitionMatrixContent.spec.js | +7 | −7 | Go to diff View file |
M | plugins/tracker/www/scripts/workflow-transitions/src/store/actions.spec.js | +10 | −8 | Go to diff View file |
M | plugins/tracker/www/scripts/workflow-transitions/src/store/getters.spec.js | +8 | −17 | Go to diff View file |
M | plugins/tracker/www/scripts/workflow-transitions/src/store/mutations.spec.js | +13 | −13 | Go to diff View file |
M | plugins/tracker/www/scripts/workflow-transitions/src/store/transition-modal/transition-actions.spec.js | +3 | −5 | Go to diff View file |
M | plugins/tracker/www/scripts/workflow-transitions/src/store/transition-modal/transition-mutations.spec.js | +2 | −1 | Go to diff View file |
M | plugins/tracker/www/scripts/workflow-transitions/src/support/factories.js | +101 | −8 | Go to diff View file |