Coder Social home page Coder Social logo

zarashima / web-test-framework Goto Github PK

View Code? Open in Web Editor NEW
11.0 4.0 6.0 462 KB

Web Java automation framework, mainly written in Java with extended CI capabilities. See project description for more details.

License: MIT License

Java 96.83% Dockerfile 1.38% Shell 1.78%
automation-framework automation-test java dependencies-injection docker guice

web-test-framework's Introduction

Codacy Badge Build Status Build Status <zarashima>

Framework Architecture

Framework Architecture

Introduction

A web automation testing framework written in Java. Support Chrome, Firefox

Features

  • Dependencies injection using Guice
  • Ensure mechanism
  • Thread-safe driver instances
  • Support different types of execution against local, pipeline or container
  • ReportPortal integration
  • Docker-ready files for easy CI/CD integration

Technologies

  • Maven
  • TestNG
  • Logback
  • WebDriverManager
  • ExtentReport
  • Docker
  • Guice
  • ReportPortal

Integration

ReportPortal

Usage

The framework export RUNWHERE environment variable for use in different cases. Different RUNWHERE used will change desired capabilities accordingly

RUNWHERE Description
LOCAL Desired capabilities for execution on local machine
PIPELINE Desired capabilities for execution on a automation pipeline
CONTAINER Desired capabilities for execution on Docker

Enable ReportPortal integration

By default, ReportPortal (RP) integration is disabled. Setup your RP properly first and then change RP settings in src/test/resources/reportproperties.properties file

Execution

As told, RUNWHERE will determine the desired capabilities against the browser under test. Example below expose RUNWHERE environment variable as LOCAL Execute maven command and pass in the browser's name. If RP is enabled, it will send results to the server.

RP Integration

Local

export RUNWHERE=LOCAL

# Parallel executions on Chrome and Firefox
mvn clean test

Container

Prerequisites

By default docker-compose file will roll up Selenium Grid automatically, and run the tests in vinh/framework-docker container

vinh/framework-docker is a custom container which is achived by below command

# Build dockerfile using vinh/
docker build -t=vinh/framework-docker .

You cange the tag's name after -t to whatever you want but ensure to change it consistently in docker-compose also

Execution

No need to export RUNWHERE=container. The commands in docker-compose has already done it for you.

Execute docker-compose command docker-compose up -d

Moreover, scale up of Chrome/Firefox nodes is possible using docker-compose command. Refer to Docker guide for more details

web-test-framework's People

Contributors

dependabot[bot] avatar zarashima avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

web-test-framework's Issues

Logger

Log test progress:

  • Use base64 path
  • Scope: Before test -> In test -> After test

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.