DOI: 10.5176/2251-2217_SEA13.03

Authors: Yogesh Kamath and Sangamesh Hebbalamath

Abstract:

The Totally Integrated Automation (TIA) portal consists of the UI component as part of the presentation layer, in addition to the other components and layers that make up the portal. One of the sub-components in the UI component is the ToolTip. ToolTips can be assigned to different UI controls (e.g. Text Boxes, Push Buttons, Data Grids, etc.) to primarily provide users with some cues, as well as to provide additional details in the form of images and hyperlinks to additional content, in support of the underlying functionality. Over a couple of releases, feedback from the usage of the sub-component in different application contexts, motivated a re-look on the ToolTip class design (e.g. responsibility and collaboration of different related objects, interfaces exposed to the clients for customizing the ToolTip in the applications) and performance aspects related to managing the ToolTip instances in memory. Consequently, a refactoring exercise was planned to address such areas. This exercise had to be taken up considering the fact that the ToolTip sub-component impacts practically all functionality of the portal that has been in production for over two releases. Thus, creation of effective test cases covering the different functionalities and code areas, were of prime importance to safeguard the code changes from any regressions getting introduced. TDD was chosen as an approach to ensure that no code gets written or changed without a test case that verifies and validates the functionality around such code. This paper discusses the learning gained from employing the TDD approach in the refactoring effort, for the UI component.

Keywords: TDD, User Interface, UI, Refactoring

simplr_role_lock:

Price: $0.00

Loading Updating cart...
LoadingUpdating...