Configuring a Jenkins environment for running tests

After you install the Integration Tester Test Execution plugin on the Jenkins server, you can configure the Jenkins environment to run the Integration Tester tests as a Jenkins build. You can also run the tests as an Ant task by using the test configuration file generated by HCL OneTest API.

Before you begin

You must have completed the following tasks:

Running tests by using the Integration Tester Test Execution plugin

Procedure

  1. Create a new project or modify an existing project on the Jenkins dashboard.
  2. Click Configure on the Project page.
  3. Click Add build step under Build.
  4. Select Run Integration Tester Tests. The following dialog is displayed:

    runtests

  5. Fill in values for the task as required.

    Enter values for Installation directory, Project, Environment, and Tests. If you leave the Installation directory blank, the following environment variables are queried during runtime to find the directory:

    INTEGRATION_TESTER_AGENT_HOME and INTEGRATION_TESTER_HOME.

    The job fails if the value is blank. These variables must be visible to the user or the service account that is running the Jenkins primary or secondary server. If you update either of the environment variables, you must restart the Jenkins primary or secondary server for the values to take effect.

    Optionally, click Advanced to view and update the other fields. For a detailed description of any field, click the question mark icon that is next to it.

  6. Click Save.

Running tests by using the Ant plugin

Procedure

  1. On the Jenkins dashboard, create a new project or modify an existing project.
  2. On the Project page, click Configure.
  3. Under Build, click Add build step.
  4. Select Invoke Ant.
  5. Click Advanced.
  6. In the Build File field, enter the location of the Apache Ant script that was generated by HCL OneTest API.
  7. Click Save.