Understanding the utility of Keyword-Driven Test Automation Tools
Keyword-driven test is a way to execute test scripts at a higher level of abstraction. The idea is similar to that of a service or subroutine in programming where the same code may be executed with different values.
Keywords are defined to represent a script, and a tool can then act as a link between the keywords and the tool executing the corresponding test script. Values may be assigned for parameters associated with the keywords.
The tools make it possible to use parameter-driven test scripts without having to change the (often complicated) scripts in the execution tool. Keywords are usually related to higher level functionality or business procedures. They may also reflect use cases.
What are the tools for Keyword driven testing?
The tools for keyword-driven testing are also known as script wrappers, because they wrap the technical part of the test (the actual test scripts and the test execution tool) so that the testers only need to know about the high-level keywords
may be held in spreadsheets or tables, and longer sequences executions of test scripts can be specified by sequences of keywords.
A test sequence defined by keywords in a table may appear like:
|Edit customer||, , Gupta|
Each keyword has a number of parameters with specific meanings.
Keyword-driven test is getting more and more sophisticated, introducing several levels of abstraction between the tester and the technical test scripts. Test wrapping tools are available commercially and as open-source, but they are also very often homemade and usually quite simple, yet very effective.
Keyword-driven testing requires a good overview of the test assignment and a high level of abstraction as all parameterization does. This is demanding but can be rewarding for the test in the long run.
What are the advantages of Keyword driven testing tools?
The advantages of these tools are primarily seen from the point of view of those controlling the test execution, especially if these are domain experts rather than test analysts.
For test executioners it is easier to use keyword-driven testing rather than test script directly, because of the following reasons:
1) Keywords that reflect the business can be chosen
2) Test execution can be done automatically by non-technical people based on the keyword lists
3) The keyword list is robust to minor changes in the software
4) The implementation of the keywords is independent of the implementation of the underlying scripts, so that the same keyword lists may be used with scripts in a number of different scripting languages being executed in different execution tools
Hard facts about Keyword driven testing
1) Using keyword-driven testing does not ease the work with the actual test scripts. They still need to be established (captured or written) and maintained, and they need to be able to be executed with different parameter values.
2) The drawback here is that extra layers are put in between the test executer and the product under testing. It requires more coordination and communication between the people involved to maintain the integrity of the layers in the testware.
3) A possible advantage rather than a drawback – is the fact that keyword-driven testing requires extra care in configuration management. This kind of testing has several layers of testware instead of “just” test scripts to keep track of and to keep consistent.