How to Run Test Cases in Azure DevOps

Harshani Perera, 28 June 2021

In Software testing, test cases are the step-by-step instructions carried out to verify the behaviour of a Software application. There are many tools to write test cases such as Excel, XMind, Testing tools or even Word. Azure DevOps is also a tool that provides the ability to create test cases easily. It has features to create test plans, test suites, charts, run test cases, replicate test cases, export to Excel and much more.

If your organisation uses Azure DevOps already, it will provide a single place to keep all your test cases together for all projects in a clear readable format. They can be accessed at a later date to reused or by a new member joining the organisation.

In this blog, I will provide you with simple instructions on how to create and run test cases in Azure DevOps.

Step 1: Login to your Azure DevOps Environment e.g., https://dev.azure.com/companyname/ and select the project you are working on.

Create a Test Plan

Step 2: Select Test Plans from the left navigation and click + New Test Plan

clip_image002clip_image004


Step 3: Fill the Name, Area Path and Iteration > Click Create

clip_image006

Create a Test Suite

This is not mandatory as you can create test cases in the Test plan however you can also nest your test cases inside a Test Suite.

clip_image008

I will create a Test Suite called ‘Functional Test Cases’.

Step 4: Click the 3 dots next to the test plan > select New Suite > select Static Suite.

clip_image010

Type the name of the Test Suite e.g., Functional Test Cases

clip_image011

Create a Test Case

Step 5: Select the suite that you want to create the Test cases i.e., in my example, I will select Functional Test Cases.

clip_image013

The important thing to notice here are the following sections: Define, Execute and Chart.

Define – To create Test cases

Execute – To run Test cases

Chart – To display results of Test cases and Test runs

clip_image014

Step 6: The blueline indicates the area you are currently in. To create a test case, select Define > Click New Test Case

clip_image016

Fill the required details on the Test Case and click Save & Close.

clip_image018

Your Test Case will be displayed. You can continue to create more Test Cases by clicking the New Test Case button.

clip_image020

Run a Test Case

Step 7: To run a test case, select the Execute section. You will see the test case you just created.

clip_image022

Step 8: Select the test case > Select either Run for web application or one of the other options that suits.

clip_image024

Step 9: Pass or fail the Test case > Click Save/Save and Close.

clip_image026

You can see the outcome of the Test case.

clip_image028

Create a Chart

The last step will show you how to create a chart with the test cases and test runs.

Step 10: Select Chart section > Click New > Select New Test result chart

clip_image030

Select Chart Type = Pie and Group by Outcome > Click OK

clip_image032

Repeat Step 10 but select New to create a test case chart. I selected a Pie Chart and to Group by State, but you can select the option that suits the chart you would like to show.

Following are the two charts I created with the test data.

clip_image034

As you can see, it is very easy to manage your testing with Azure DevOps. It allows to create test plans, test suites, test cases, run them and create charts. You can replicate these test cases for regression testing in a new test suite and they are in an easy-to-read format.

This is a basic guide on what Azure DevOps can do. In my future blogs, I will show you some more advanced features that can help you test more efficiently using Azure DevOps.

// Tactix campaign Linkedin Tag_April 2022