Documentation

Looking for something in particular?

Parallel Execution in Microsoft Azure Pipelines using Multiple build.xml Files

Microsoft Azure Pipelines is a cloud service that you can use to automatically build and test your code project and make it available to other users. It works with just about any language or project type. We provided instructions on setting Microsoft Azure Pipelines parallel execution using build.xml files.

Azure Pipelines combines continuous integration (CI) and continuous delivery (CD) to constantly and consistently test and build your code and ship it to any target.

This support article describes how to execute parallel execution in Azure Pipelines with these easy steps. 

You can divide the test cases that you need to execute into multiple suites, and each suite can be part of a build.xml file. In this example, we use 20 test cases with two build.xml files andten0 different test cases associated with each.

To start, you must make the following changes to the provar.home and testproject.home variables to include the path of the agent system.

 

Step 1: Make the following configuration changes in the Azure Pipelines. You will configure Azure Pipelines with an ANT task. To get started, click Variables.

Step 2: Create a variable BUILDFILE with the value:

Build1.xml,build2.xml

Note: The value is the name of the different build files created above. It could be different for you.

screenshot of configuration changes in the Azure Pipelines with an ANT task

Step 3: Click Tasks and then the agent job. 

Step 4: Under Parallelism, select Multi-Configuration.

Step 5: Complete the confirmation using the following configuration information. 

Multipliers: BUILDFILE

(Note: This is the variable name defined in Step 3.)

A maximum number of agents: Provide the number of agents you want to execute test cases in parallel.

Provide the number of agents you want to execute test cases in parallel execution with Microsoft Azure Pipelines

Step 6: Select the ANT task.

Step 7: Complete the confirmation using the following configuration information. 

  • ANT build file: <Path to build file>\$(BUILDFILE)
  • Check to Publish to Azure Pipelines under JUnit Test Results
  • Test results files: <Path to Result file from build.xml>\junit.xml

confguring ANT build file published to Azure Pipelines under JUnit Test Results

Step 8: Changes can also be made to the build.xml files to create separate result files. (See command below.) Otherwise, one agent’s result will override the other’s result.

<property name=”testproject.results” value=”D:\a\1\s\ANT\Results\${env.BUILDFILE}”/>

Step 9: If you execute Azure Pipelines now, you should see two agents running – each executing their respective build file.

Review Provar on G2
Documentation library

Trying to raise a case with our support team?

We use cookies to better understand how our website is used so we can tailor content for you. For more information about the different cookies we use please take a look at our Privacy Policy.

Scroll to Top