top of page
Search

Introduction to Allure reporting


Introducing the Allure Report, a powerful open-source reporting tool that allows you to visualize and analyze your test results in a sleek and user-friendly way. If you're a software tester, you know that test reports are critical for test analysis and to communicate test results to your stakeholders. The Allure Report helps you do just that, presenting your test results in a beautiful and intuitive way.

In this tutorial, we'll guide you through the process of integrating the Allure Report into your existing software testing framework. With all the benefits that the Allure Report provides, this integration is a must-have for any testing team. Let's get started.


 

1. Add maven dependency as per the cucumber-java version.

<dependency>

   <groupId>io.qameta.allure</groupId>

   <artifactId>allure-cucumber4-jvm</artifactId>

   <version>2.22.0</version>

</dependency>

 

For example, my cucumber version is 4.6.0. Therefore, I have added allure-cucumber4-jvm.

 

2. Update TestRunner.java file

 

 



3. Now, when we execute our tests using TestRunner file, allure-results folder will be generated that consists of .json files.

 



 

4. If we need to see reports in .html format. We need Node.js and npm modules installed on our device.

 

Step 1: Download the Installer

Download the Windows Installer from NodeJs official website. Make sure you have downloaded the latest version of NodeJs. It includes the NPM package manager.

Here, we are choosing the 64-bit version of the Node.js installer.

The LTS (Long-term Support) version is highly recommended for you. After the download of the installer package, install it with a double-click on it.



Now .msi file will be downloaded to your browser. Choose the desired location for that.

Step 2: Install Node.js and NPM

After choosing the path, double-click to install .msi binary files to initiate the installation process. Then give access to run the application.



You will get a welcome message on your screen and click the “Next” button. The installation process will start.



• Choose the desired path where you want to install Node.js.

• By clicking on the Next button, you will get a custom page setup on the screen. Make sure you choose npm package manager , not the default of Node.js runtime . This way, we can install Node and NPM simultaneously.



You should have 143MB of space to install Node.js and npm features.

The following features will be installed by default:

• Node.js runtime

• Npm package manager

• Online documentation shortcuts

• Add to Path

• Bang! The setup is ready to install Node and NPM. Let’s click on the Install button so hard!




Step 3: Check Node.js and NPM Version

• If you have a doubt whether you have installed everything correctly or not, let’s verify it with “Command Prompt”.

Command Prompt window will appear on the screen.



To confirm Node installation, type node -v command.

To confirm NPM installation, type npm -v command.



And you don’t need to worry if you see different numbers than mine as Node and NPM are updated frequently.

5. Add Allure command line

 

Open Command Prompt ->

 

C:\>npm install -g allure-commandline --save-dev


 

6. Now go to directory in which allure-results folder was generated and type allure serve to generate beautiful .html reports.

 



7. HTML reports




 


29 views0 comments

Comments


bottom of page