Skip to content

Latest commit

 

History

History
56 lines (35 loc) · 1.39 KB

README.md

File metadata and controls

56 lines (35 loc) · 1.39 KB

Cypress Tests

This project has the tests using Cypress for studio both local and test environments.

Getting started

These instructions will get you run the integration tests on local studio.

Installing dependencies

    yarn --immutable # only needed first time, or when dependencies are updated

Starting the solutions for testing studio

The Prerequisites defined here must be satisfied to start the solution.

Run the development/setup.js script as described here to set up test users and relevant test data.

Run Altinn Studio tests

The commands should be run in an order that makes sure the tests are intact on the subsequent runs.

Note: Use cmd or git bash to run the scripts.

  1. Setup: before all the tests
    yarn run before:all
  1. Tests on different solutions of studio
    yarn run test:all -e environment=local
  1. Cleanup: after all the tests
    yarn run after:all
  1. To run a single test case open Cypress runner using
    yarn run cy:open -e environment=local

Formatting files with Prettier

    yarn run prettier:check # For checking the files deviating standards
    yarn run prettier:format # format and save the files based on config