A RQM usage anti-pattern: multiplying test scripts associated to a test case

During discussions with customers who start using Rational Quality Manager,  I sometimes get the following questions:

I’ve associated MULTIPLE test scripts to my test cases. Now when I execute them, the LAST execution status returned when selecting a specific test script OVERRIDES previous execution status (with a different test script associated).

Seems like RQM is “loosing” previous execution status each time !  This is a bug, right ?

Actually no, this behavior is NOT weird. You need to get the logic of the RQM tool wrt the semantic of the relationship between test cases and test scripts.

RQM-TestCaseTestScript-nm-Linking

Let’s recap it here :

  • A Test Case answers the question : “what am I going to test ?” It defines the things you need to validate to ensure the system is working correctly and is written to be environment-agnostic.
  • As sketched in the model above, you could have AS MANY test scripts associated to a test case than desired…

BUT there are some best practices associated to this model. You can have multiple test scripts associated to a test case provided each test script tests the SAME functionality. This would typically be the case for:

  • Running a test case in different test environments (thus implying non identical steps).
  • When you have a manual test script and a robotic test script (e.g. RPT, RFT, Selenium, etc.)

Once this basis is stated, customer figure out they have followed a RQM anti-pattern which needs to be fixed.

While the solution to adopt is very dependent on the customer context, a possible remediation includes a refactoring work through the splitting of the test case content into several test cases, the merging of the multiple test scripts into a single test script (provided this doesn’t create an ugly monolithic test piece), etc.

Question: for running a test case in different test environments (not an anti-pattern), where shall the choice of the test script be done ?

RQM-2TCERS-2TestScripts

Answer:

  • As an example, above snapshot presents the TCER section of the test case TC01.
  • It includes 2 TCERs (which were generated for 2 different test environments: TC01_Chrome… and TC01_Firefox…). Test script Script for Chrome addresses TC01_Chrome… environment and Test script Script for Firefox addresses TC01_Firefox… environment.
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Create a free website or blog at WordPress.com.

Up ↑

%d bloggers like this: