Code Monkey home page Code Monkey logo

test-automation-demo's Introduction

Automation Test Demos

This is a Selenium Webdriver based automated test framework designed for demonstration purposes. The source code is at https://github.com/doeritlk/test-automation-demo.git.

This framework contains:

  • Parameterised Table tests - Annotate the tests with @Table and test data in @Row with columns, external data sources could be plugged in if requires; using table cell values as keys

  • Test Summary in an HTML page - Once tests run, results and the summary will be rendered into an HTML page

  • Browser choices - Chrome, Firefox and Headless

  • Gerkin language inspired tests - Given, When, Then are java method stubs which are translated in the HTML page.

  • Screenshot capture - Captured screenshot will be attached to the HTML page Web Page Object oriented tests - Test should interact with pages as objects, the signup test is a good example.

  • Optional Sequence diagram support - This library can generate a sequence diagram using the hints provided, this is useful if we your system interacts with have multiple dependent systems.

How do I get set up?

You need to have latest Oracle Java (JDK 1.8+ client VM) and Apache Maven installed in your box. If you use server JDK/JRE, that will cause issues when running tests in headless mode.

In order to build the project, go to project directory and use:

mvn clean install

That will buid and run all tests in the project.

The default webdriver.type is set to Chrome. You could change the type of driver that you need to run the tests against passing JVM arg -Dwebdriver.type. The supported values are Headless, Chrome, Firefox.

For example, if you wish to use Headless driver:

-Dwebdriver.type=Headless

The headless mode uses a driver called JBrowserDriver. The version which has been used in this project is not an official release. This is because current release has some known issues which prevent getting element values correctly.

The drivers are in test-automation-demo/drivers and they are for the Mac OS. If you wish to use the demo on other platforms, please download OS specific driver, copy to test-automation-demo/drivers directory and update the profile in pom.xml to refer to the new driver.

Dependencies

An extension of the BDD test library called yatspec (https://github.com/bodar/yatspec) has been used in the project. The source code is at https://github.com/doeritlk/yatspec-ext.git.

test-automation-demo's People

Contributors

doeritlk avatar

Watchers

James Cloos avatar Kolapo avatar

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.