Ant can also be configured to run tests in continuous integration with Jenkins. In this recipe, we will set up Jenkins to run tests with Ant.
Running tests with Jenkins and Ant needs both the tools installed on the machine. Refer to the Using Ant for Selenium WebDriver test execution and Configuring Jenkins for continuous integration recipes to install and configure Ant and Jenkins respectively.
Let's configure Jenkins and Ant to run tests in CI:
Navigate to Jenkins Dashboard (
http://localhost:8080
by default) in the browser window.On Jenkins Dashboard, click on the New Job link to create a CI job.
Enter
Selenium Cookbook
in the Job name: textbox.Select the Build a free-style software project radio button, as shown in the following screenshot:
Click on OK.
On the job configuration page, go to the Source Code Management section...