Skip to content

Latest commit

 

History

History
54 lines (37 loc) · 1.32 KB

File metadata and controls

54 lines (37 loc) · 1.32 KB

Lightweight C# Selenium & NUnit Framework

This framework leverages C#, Selenium, NUnit, POM, Allure Report, and automatic screenshot capture for efficient and comprehensive testing.

Prerequisites

Before running the tests and generating reports, make sure you have the following installed:

  • .NET SDK (8.0 or higher)
  • Selenium WebDriver
  • Allure Commandline
  • NUnit Console (optional, if you prefer to run tests through NUnit)

Run Locally

  1. Clone the repository to your local machine

  2. Building the Project

Make sure the required dependencies are installed. Run the following command to restore NuGet packages:

  dotnet restore
  dotnet build
  1. Running Tests

You can run the tests with the following command:

  dotnet test
  1. Generating Allure Report

To generate an Allure Report, run the following steps:

Run the tests with the following command to specify the logger for Allure:

  dotnet test --logger "nunit;LogFilePath=allure-results/results.xml"

After running the tests, generate the Allure report:

  allure generate --clean

To serve the report locally:

  allure serve allure-results

This will start a local server and open the Allure Report in your browser.

  1. Screenshots for failing tests will be saved in a 'screenshots' folder at the project root directory