Run the REDCap Cypress Test Suite - vanderbilt-redcap/redcap_cypress GitHub Wiki

Recommended: Download the REDCap Cypress Developer Toolkit

The fastest way to get started with testing in the REDCap Cypress Testing Framework is to download the developer toolkit here: https://github.com/vanderbilt-redcap/redcap_cypress_docker

Please read the README.md before proceeding.

Open Cypress Test Suite

If you are using the REDCap Cypress Developer Toolkit, starting the test environment is easy - just one command:

./run.sh

Headless Mode

If you run your tests in a Continuous Integration (CI) pipeline, you will want to run the tests in headless mode.

To do so, issue the following command at the redcap_cypress directory:

npx cypress run

You can add several arguments to run command. Below is an example of what Vanderbilt runs in the pipeline:

CYPRESS_prettyEnabled=true npx cypress run --record --key $RECORD_KEY --parallel --group core-tests --browser chrome --reporter junit --reporter-options=mochaFile=coverage/test-results/[hash].xml || true