Git Product home page Git Product logo

codeceptjs-e2e's Introduction

CodeceptJS E2E

CodeceptJS E2E Framework with Cucumber and Saucelabs cloud

Build Status Maintainability lerna License Codecept-Logo-001.jpg

This framework contains Gherkin BDD Tests with CodeceptJS & uses Should.JS assertion library. Intgrated with Saucelabs to run on Multibrowsers in Parallel

  • Why BDD? Read my Medium post here

  • Run All feature files in Parallel

  • Run All feature files on Multi-Browsers - run them all in Parallel

  • Scenarios are written in Cucumber Gherkin BDD Syntax, a.k.a .feature files. Prefer writing Declartive Test Scenarios

  • Run on SauceLabs. Single browser or Multi-Browsers in Parallel

  • Uses Should.js Assertions Library. Various assertions with examples are available here

  • Reduces Flakiness with RetryFailedSteps plugin and a Webdriver's SmartWait

  • Page objects follow <name_of_page>.page.js naming pattern, and created under pages directory

  • Step Definitions files follows <name_of_step>.steps.js naming pattern, and created under step_definitions directory

  • Soft Assertions: Collect more errors in a single run rather than failing test at first failure!

Benefits of this Framework

Screen-Shot-2019-12-19-at-8-33-02-PM.png Screen-Shot-2019-12-19-at-8-33-28-PM.png Screen-Shot-2019-12-19-at-8-32-29-PM.png

Get Started : Interactive CLI

This framework comes with the Interactive CLI which will setup the entire framework in one-go.

Follow the below steps to launch CLI, and follow the CLI instructions. CLI also runs the Sample Github tests to test your setup (this step is optional)

Yarn is required. Install Yarn

    git clone https://github.com/gkushang/codeceptjs-e2e.git
    cd codeceptjs-e2e/packages/codeceptjs-cucumber
    yarn
    npm run cli

CodceptJS-Cucumber : E2E Framework

CodeceptJS E2E Framework with Cucumber and Saucelabs Integration

  • Interactive CLI to get started
  • Run Cucumber Scenarios on local browsers or chrome:headless
  • Run all the Feature files in Parallel
  • Run tests on Sauce Labs
    • Single Browser
    • Multi Browsers. Runs all the Feature files in Parallel on Multibrowsers
  • Soft Assertions: Collect more errors in a single run rather than failing test at first failure!
  • Launch HTML report

To get started, follow the instructions on codeceptjs-cucumber

CodeceptJS-Saucelabs : Single or Multibrowsers in Parallel

CodeceptJs Integration with Saucelabs. Ease of Configuration!

  • Easy to run tests on Saucelabs with command
  yarn acceptance --profile sauce:chrome
  • Easy to run tests on Multibrowsers / Cross-Browsers. All tests in Parallel with command
  yarn acceptance:multibrowsers --profile sauce:chrome,ie,safari

To get started, follow the instructions on codeceptjs-saucelabs

CodeceptJS-Shared : Shared Master Configurations and Helpers

Shared Master Configurations & Helpers

To get started, follow the instructions on codeceptjs-shared

Docker & Jenkinsfile

Codecpetjs-e2e packed into the container with Node and Java.

Codecpetjs-e2e Docker makes it very simple to build your CI Job.

To run your Codecptjs-e2e tests on Saucelabs thru Jenkins, add below stage to your Jenkinsfile:

	stage('CodeceptJS Acceptance') {
            sh "docker run --env SAUCE_KEY --env SAUCE_USERNAME -v ${env.WORKSPACE}/:/acceptance --rm gkushang/codeceptjs-e2e --debug --profile sauce:${browser}"
        }
  • If you tests uses any enviornment variables, pass to the Docker image thru --env param as shown above
  • Select browser on Saucelabs thru ${browser} environment variable
  • Mount your workspace to the Docker container with -v param as shown above.

codeceptjs-e2e's People

Contributors

gkushang avatar cthorsen31 avatar

Stargazers

Roman avatar

Watchers

James Cloos 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.