Giter Club home page Giter Club logo

hmcts.sscs-ccd-e2e-tests's Introduction

TEMPLATE CCD End2End Journey Tests

Purpose

This service is to help people to run End2End Journey Tests for their service, without needing to start from scratch.

The repo consists of Cucumber test scenarios for testing different cases. These use Protractor to interact with a Chrome browser (via Puppeteer), which runs without showing the browser (i.e. headless) by default.

Getting Started

Prerequisites

Running the application requires the following tools to be installed in your environment:

Install dependencies

Install dependencies by executing the following command:

$ yarn install

Running the tests

The tests will need to be given valid credentials for a Case Worker, supplied by setting the environment variables TEST_CASEOFFICER_USERNAME and TEST_CASEOFFICER_PASSWORD and then executing the e2e tests, e.g.

$ TEST_CASEOFFICER_USERNAME=? TEST_CASEOFFICER_PASSWORD=? yarn e2e

Running the tests against a local prod ccd version

$ ./bin/local-prod-test.sh

If you wish to see the browser running the tests simply set the TEST_E2E_HEADLESS environment variable to false

Updating the project for your service

You need to make changes everywhere there is a TODO: comment to make it relevant to your service:

  • Jenkinsfile_nightly
  • service.conf.js

i.e. changing running environment from local to demo or to aat. To run it locally, you need to set docker and other relevant services.

Running locally

If you have got the latest sscs-docker setup and running you can run all the e2e tests with

$ TEST_E2E_USE_PROXY=false TEST_E2E_URL_GATEWAY='http://localhost:3453' TEST_E2E_URL_WEB='http://localhost:3451' TEST_JUDGE_USERNAME='[email protected]' TEST_JUDGE_PASSWORD='Pa55word11' TEST_DWP_USERNAME='[email protected]' TEST_DWP_PASSWORD='Pa55word11' TEST_E2E_HEADLESS=false TEST_CASEOFFICER_USERNAME='[email protected]' TEST_CASEOFFICER_PASSWORD='Pa55word11' yarn e2e

to run tests by their scenario tag append the tag in the feature script

 --cucumberOpts.tags=@adjournment

Other tasks

To ensure your code is clean (i.e. linting):

$ yarn lint

To perform NSP dependency checks:

$ yarn test:nsp

hmcts.sscs-ccd-e2e-tests's People

Contributors

bkpatel81 avatar burale avatar chrisdavecm avatar danielbe11 avatar dependabot[bot] avatar gokul-sol avatar lee365 avatar rasikasri avatar rob-doherty avatar ryandac avatar snyk-bot avatar tpetkovic 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.