Minimize (Direct) Use of Custom Actions
Custom actions were originally added to the Creator modelling language to provide an extension point for expert users, i.e., to enable to specify interactions via interfaces that are neither GUI nor message based. In practice, however, many non-expert users have started to extensively use custom actions, e.g., to redefine pre-defined GUI actions to affect especially the textual rendering in test cases. Note the proper way to affect textual rendering of actions is to customize scripting backends – not to use custom actions. In addition, many conceptual mistakes (like having input actions named “Verify that …”) are commonly made. Finally, the effort required to maintain models with loads of custom actions is significantly higher compared to using pre-defined actions.
Recommendation: Try to use generic GUI modelling support wherever possible and avoid redefining GUI actions using custom actions. Consult expert users before adding any custom action to your model. Ensure there is not already a structure diagram library available that addresses your need. |
A rule of thumb since years in the Conformiq manual is to limit the amount of custom action definitions in a project to a maximum of 20% of the overall specified interactions (not counting custom action definitions within SD libraries).
What many users do not realize is that direct use of custom actions is problematic in the next step, i.e., the automation of generated tests. They cannot easily be converted into test automation code since – by definition - they can mean anything, i.e., each custom action has to be manually automated.
Recommendation: Try to use or define custom actions mainly in the context or as part of SD libraries. Also, keep all Custom Actions in a single SD file, so that this SD file can be verified for existing actions before creating new one. Discuss with Automation COE on “best definition” of a ne Custom Action. This fixes custom actions, avoids duplicity and enables automation. |
Note that this idea can be easily extended, e.g., automation teams can provide and maintain SD libraries with custom actions based on keywords available in their automation framework which will enables a fully automatic conversion to tests running in their framework.
Related content
Copyright © 2023 Conformiq and its subsidiaries. All rights reserved.