Rational QualityArchitect 
COM Component Testing Sample Scripts

 

There are two sample unit tests and two sample scenario tests in this directory structure which are available to run immediately.  These scripts are samples of those that are created during the standard COM demo.  There is also a sample stub which can be deployed to the ClassicsCD.COM application.  Finally, there is a self-extracting zip of desktop shortcuts.

This READ ME file has three main sections with information on these topics:

 

Running the Sample Tests

File To Open Description
Unit Test\Unit Test.vbp This is a basic unit test of the IPayment_confirmOrder method on the BusinessServices component.  If you run the test against the component as it ships with RUD, the test will show failures in the log.  If you deploy the stub component, then the test will show passes in the log.  In either case, the test should run to completion without errors.
Unit Test with PureCoverage\Unit Test with PureCoverage.vbg This is the same test code as above, however the Visual Basic project has been modified to include the source code for the components under test.  This allows the PureCoverage integration to report source code coverage for the test.  In order to collect PureCoverage data, before executing the code, you must engage PureCoverage within VB.  This can be done from the umbrella icon on the PureCoverage toolbar or from the PureCoverage menu.

NOTE: You cannot run this test with the stub deployed as the stub will raise an error which VB will trap, preventing completion of the test.

Scenario Test\Scenario Test.vbp This is the LoginAndShop scenario test from the demo script.  This script must be executed twice.  After the first execution, the log will report white information lines indicating that it has captured baseline data.  Subsequent runs will report gree pass lines indicating that TestManager has compared the returned results from the SQL queries that are executed during the test.
Scenario Test with PureCoverage\Scenario Test with PureCoverage This is the same test code as above, however the Visual Basic project has been modified to include the source code for the components under test.  This allows the PureCoverage integration to report source code coverage for the test.  In order to collect PureCoverage data, before executing the code, you must engage PureCoverage within VB.  This can be done from the umbrella icon on the PureCoverage toolbar or from the PureCoverage menu.

 

Deploying the DataServices.OrderModifier Stub

To deploy the stub, complete the following steps:

 

Creating the Desktop Shortcuts

Double click and select Unzip to create desktop shortcuts for all the files accessed in the demo.  The demo is much cleaner if you use these as opposed to continually digging files out of Windows Explorer.  Once on the desktop, a quick way to access these shortcuts is to hit Windows Key + D to minimize all applications and reveal the desktop.