Skip to content

openboxes/openboxes-e2e

Repository files navigation

Openboxes E2E tests

End to end testing for OpenBoxes

Setup

Required

  • NPM 6.14.6
  • Node 14+

Install Dependencies

npm run install

npx playwright install

Environment Variables

Environment variables facilitate the configuration of our testing project by allowing us to set appropriate configuration settings. A sample file can be located in the root directory of the project under the title .env.example. To configure this project effectively, it is imperative to create a .env file and declare all necessary variables within it.

APP_BASE_URL
base URL of the running openboxes environment

CI [optional]
true or false flag indicating whether tests are running in Continuous Integration.

USER_MAIN_USERNAME
USER_MAIN_PASSWORD
login credentials of the test user that will be used for most of the tests

LOCATION_MAIN
locationId of the default location that will be used in most of the tests

LOCATION_NO_MANAGE_INVENOTRY_DEPOT
locationId of the location with no manage inventory activity code

Scripts

Running tests

For more information on available flags when running tests in playwright reffer to the documentation.

npm run test

To add a flag to the npm script, do the following eg. npm run test -- --headed

Linting project

To check if there are any linter errors that require attention run the following command

npm run lint

If you wish to handle these errors automatically run

npm run lint-fix

Code formatting

To format your code run the following command

npm run format

About

End to end testing for OpenBoxes

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published