To run the code :
- Clone/download the repository.
- Open the project directory in the terminal.
- Run the following commands in the terminal to run all tests:
npm i
npx codeceptjs run --steps
To run a certain test only, use:
npx codeceptjs run {path to file} -- steps
Below are additional flags that can be used when running tests and their effects :
- --features : run only Gherkin tests
- --tests : run only non-Gherkin tests
- --ai : enables ai for self-healing tests and helping with writing tests during pause
- --reporter {reporter_name} : enables using the reporter specified in reporter_name. Currently available reporters are the default reporter and Mochawesome (produces report in a HTML file inside the output folder).
Testomat.io reporting method:
- Load respective API key before using check command:
set TESTOMATIO={api key here}
Classic:
npx check-tests@latest CodeceptJS "**/*{.,_}{test,spec,cy}.ts" --typescript
BDD:
npx check-cucumber@latest --codeceptjs "**/*.feature" --dir features
- Open testomat.io and review your runs here.