Running Tests

In this exercise, you will define the Mercury Tours Site test set. You will also set failure rules for the test set to instruct ALM how to proceed in the event that an automated test in the test set fails. Depending on whether you are an ALM Edition user, you can either define a Functional test set or a Default test set.

Note:  

Running Tests in a Functional Test Set

When you run tests from a Functional test set, ALM uses Lab Management to execute the tests on remote testing hosts equipped with the testing tools. Lab Management updates ALM with the results of your tests. You can run all tests in a Functional test set or run specific tests. You can use the Execution Grid tab to run a test set immediately. You can also use the Timeslots module to reserve resources for a test to run in the future.

You can run build verification suites in the same way as test sets. You use the Build Verification module to run a build verification suite immediately, and you use the Timeslots module to reserve resources for a build verification suite to run in the future.

In these exercises, you will learn about the following:

Back to top

Running a Functional Test Set in the Test Lab module

You can run tests from a Functional test set immediately using the Execution Grid.

In this exercise, you will run the Mercury Tours Site test set in the Test Lab module.

To run a Functional test set in the Test Lab module:

  1. Make sure the Test Lab module is displayed.

    On the ALM sidebar, under Testing, select Test Lab.

  2. Select the Mercury Tours Site test set.

    In the test set tree, expand the Cycle 1 - New Features test set folder under Service Pack 1. Select the Mercury Tours Site test set.

  3. Open the Run Functional Test Set dialog box.

    Click the Run Test Set button. The Run Functional Test Set dialog box opens.

  4. Run the test set.

    Click the Run button. ALM uses Lab Management to execute your test on a testing host with the required testing tool.

  5. View the progress of the run.

    ALM opens the Execution Report page, which displays the current state and results of the tests you executed. You can refresh the page, stop tests, and view an Event Log for the entire run.

  6. Close the Execution Report.

    After the test run is complete, close the Execution Report page.

Back to top

Scheduling a Functional Test Set in the Timeslots Module

You can reserve resources for the execution of a Functional test set using the Timeslots module.

In this exercise, you schedule the Mercury Tours Site test set in the Timeslots module.

To schedule a Functional test set in the Timeslots module:

  1. Make sure the Timeslots module is displayed.

    On the ALM sidebar, under Testing, select Timeslots.

  2. Create a new Timeslot.

    On the Timeslots toolbar, click the New Timeslot button. The Timeslot Reservation dialog box opens.

  3. Schedule your Functional test set.

    1. In the Run field, select Functional Test Set.

    2. In the Start field, select Automatically.

    3. In the Name field, type Mercury Tours Nightly.

    4. Click the [none] link in Select a test set, and select the Mercury Tours Site test set.

    5. Use the Start Time and End Time fields to schedule the test set to run from 20:00 to 22:00.

    6. A host is automatically added to the Requested Hosts grid.

    7. Click the Calculate Availability button to check that the timeslot is valid.

  4. Submit the timeslot.

    Click Submit.

Back to top

Running Tests in a Default Test Set Manually

When you run a test manually, you follow the test steps and perform operations on your application. Then, you compare the expected results with the actual outcome and record the results. You can execute a manual test as many times as needed. The results are stored separately for each run.

Note: In these exercises, you run Default test sets. If you are using ALM Edition with Lab Management, you already ran a Functional test set. To continue in the tutorial, proceed to Viewing and Analyzing Test Results.

You can run both manual and automated tests manually as part of a Default test set. You can also choose to run a single test or to run an entire test set.

You run manual tests in ALM using Sprinter, Micro Focus’s solution for manual testing. If you are not working with Sprinter, you run tests manually using Manual Runner.

In these exercises, you will learn about the following:

Back to top

Running with Sprinter

Sprinter provides advanced functionality and tools to assist you in the manual testing process. Sprinter is fully integrated with ALM, enabling you to get the maximum benefit from both solutions.

Note: For information on installing Sprinter, see Before You Begin.

In this exercise, you will run the Credit Cards test. This test contains three test configurations. For the purpose of this exercise, you will perform the steps without testing them against the Mercury Tours application.

To run a test using Sprinter:

  1. Open Sprinter.

    1. If the Test Lab module is not displayed, on the ALM sidebar, under Testing, select Test Lab.
    2. Click the Execution Grid tab.

    3. Click the Run arrow and select Run with Sprinter. Micro Focus Sprinter opens.

  2. Select the instances to run from the test set.

    1. Click the Open ALM Tests button. The Open dialog box opens.

    2. In the left pane, expand the Root folder. Under Service Pack 1, expand Cycle 1 - New Features. Select the Mercury Tours Site test set. The test set is displayed.

    3. Select American Express, Visa, and MasterCard check boxes. Click Open.

  3. Display the test steps to run the American Express instance.

    Click the Run the Active Test button. The Steps pane is displayed.

  4. Perform the first step.

    1. Click the Actual Result button. In the Actual Result dialog box, type: The Mercury Tours site opens. Click OK.
    2. Click the Passed Selected Step button.
  5. Perform the second step.

    1. Click the Actual Result button. In the Actual Result dialog box, type: Flight details and preference are entered. Click OK.
    2. Click the Passed Selected Step button.
  6. Pass the remaining steps.

    Click the Passed Selected Step arrow and select Pass All.

  7. Continue on to the Visa instance.

    Click Next Test. Sprinter advances to the next instance in the test list.

  8. Pass all steps of the Visa instance.

    Click the Passed Selected Step arrow and select Pass All.

  9. Continue on to the MasterCard instance.

    Click Next Test. Sprinter advances to the next instance in the test list.

  10. Pass all steps of the MasterCard instance.

    Click the Passed Selected Step arrow and select Pass All.

  11. Fail the last step on the MasterCard instance.

    Select Step 8 and click the Fail Selected Step button.

  12. End the run and view run results.

    1. In the upper-right side of your screen, click Run Control. The Run Control pane opens.

    2. Click the End Run button.

    3. Under Tests, you view the run results.

  13. View results in the Execution Grid tab.

    Close Sprinter.

    The test run results are displayed in the execution grid. The Last Run Report pane displays run results of each test step.

Back to top

Running with Manual Runner

If Sprinter is not installed you can run tests manually using Manual Runner.

In this exercise, you will run the Credit Cards test. This test contains three test configurations. For the purpose of this exercise, you will perform the steps without testing them against the Mercury Tours application.

To run a test using Manual Runner:

  1. Make sure the Cycle 1 - New Features test set folder is displayed in the Execution Grid.

    1. If the Test Lab module is not displayed, on the ALM sidebar, under Testing, select Test Lab.

    2. In the test set tree, expand the Cycle 1 - New Features test set folder under Service Pack 1. Select the Mercury Tours Site test set.

    3. Click the Execution Grid tab.

  2. Select the instances to run from the test set.

    Press the CTRL key and select the following instances in the Execution Grid: American Express, Visa, and MasterCard.

  3. Open Manual Runner.

    Click the Run arrow and select Run with Manual Runner. The Manual Runner dialog box opens.

  4. Start the test run.

    Click the Begin Run button. The Manual Runner dialog box opens.

  5. Perform the first step.

    1. In the Actual box, type: The Mercury Tours site opens.

    2. Click the Pass Selected button. Step 2 is displayed.

  6. Perform the second step.

    1. In the Actual box, type: Flight details and preference are entered.

    2. Click the Pass Selected button. Step 3 is displayed.
  7. Pass the remaining steps.

    Click the Passed Selected arrow and select Pass All.

  8. End the run.

    Click the End Run button to end your test run.

  9. Continue on to the Visa instance.

    Click the Begin Run button. The Manual Runner dialog box opens. Note the name of the instance in the title bar.

  10. Pass all steps of the Visa instance.

    Click the Passed Selected arrow and select Pass All.

  11. End the run.

    Click the End Run button to end your test run.

  12. Continue on to the MasterCard instance.

    Click the Begin Run button. The Manual Runner dialog box opens. Note the name of the instance in the title bar.

  13. Fail all steps of the MasterCard instance.

    Click the Fail Selected arrow and select Fail All.

  14. End the run.

    Click the End Run button to end your test run.

  15. View the run results in the Execution Grid.

    Following the execution of your tests, you can view the run results of your last run in the Execution Grid.

  16. View the results of each test step in the Last Run Report pane.

    1. Select one of the recently run instances. If the Last Run Report pane is not displayed, click the Show button on the bottom of the pane. The Last Run Report pane is displayed below the Execution Grid.

    2. Click each step to view its description, as well as the expected and actual results.

Back to top

Running Tests in a Default Test Set Automatically

When you run an automated test from a Default test set, ALM automatically opens the selected testing tool, which runs the test on your local machine or on remote hosts, and imports the results to ALM.

You can run all tests in a test set or run specific tests. You can run tests from the Execution Grid tab or the Execution Flow tab.

In this exercise, you will run a UFT test.

Note: For prerequisites to running a UFT test, see Before You Begin.

To run a test automatically:

  1. Make sure the Test Lab module is displayed.

    On the ALM sidebar, under Testing, select Test Lab.

  2. Select the Number of Passengers test.

    1. In the test sets tree, expand the Mercury Tours Web Site test set folder. Under Functionality And UI, select the Mercury Tours Functionality test set.

    2. Click the Execution Grid tab.

    3. Select the Number of Passengers test.

  3. Open the Automatic Runner dialog box.

    Click the Run button. The Automatic Runner dialog box opens and displays the selected test.

  4. Set the test run settings.

    Select the Run All Tests Locally check box to run the test on your local computer.

  5. Run the test.

    Click the Run button. ALM opens the selected testing tool automatically and runs the test. You view the test execution progress in the Status column.

  6. Close the Automatic Runner dialog box.

    After the test run is complete, choose Run > Exit.

  7. View a summary of test results in the Execution Grid.

    The Execution Grid displays the updated status for the test run. Results for each test step appear in the Last Run Report pane.

  8. Close UFT.

    In UFT, choose File > Exit.

Back to top