Creating a PHPUnit Test Suite

This procedure demonstrates how to create a PHPUnit Test Suite for running a number of PHPUnit Test Cases at once. This function is useful if you have a number of tests which you would like to unify into one.

Before creating the PHPUnit Test Suite, you must have created all your separate PHPUnit Test Cases.

 

 

Instructions on how to complete a procedure

To create a PHPUnit Test Suite:

  1. In PHP Explorer View, right-click the project which contains your PHPUnit Test Cases and select New | Other | PHP | PHPUnit | PHPUnit Test Suite.
    The "New PHPUnit Test Suite" dialog appears.

New PHPUnit Test Suite dialog

  1. The 'Tests to include' category will show the available test cases within the project. Cilck Add to choose the test cases you would like to include in the Test Suite.

  2. Click Finish.

A PHPUnit Test Suite will be created, integrating all the separate PHPUnit test cases, and will be added as a file to your project.

See the Running a PHPUnit Test Suite topic for more on how to run your PHPUnit Test Suite.