Skip to content
testing.md 1.53 KiB
Newer Older
Kevin Di Lallo's avatar
Kevin Di Lallo committed
# Testing Procedure

## Summary

The AdvantEDGE platform currently supports end-to-end testing using [Cypress](https://www.cypress.io/). This Node-based Javascript testing tool simulates user interactions with the frontend and validates expected UI updates. It captures DOM snapshots for each event and allows for quick debugging of issues within the browser.

## Prerequisites

- Set up [AdvantEDGE Development Environment](setup_dev.md)
- Set up [AdvantEDGE Runtime Environment](setup_runtime.md)

## Set up testing environment

Before running the tests, do the following:

- [Build AdvantEDGE](build.md)
- [Deploy AdvantEDGE](deploy.md)
Kevin Di Lallo's avatar
Kevin Di Lallo committed
- Install the demo1 scenario:
  - [Import demo1 scenario](use/base-ops.md#import-demo1-scenario-in-advantedge)
  - [demo1 scenario information](../examples/demo1/README.md)
Kevin Di Lallo's avatar
Kevin Di Lallo committed
- Make sure there is no deployed scenario

Test specification files are located [here](../js-apps/meep-frontend/cypress/integration/tests)
### Cypress CLI
# Run Cypress tests using CLI
cd js-apps/meep-frontend
npm run cy:run
>**NOTE**<br>
>Default AdvantEDGE URL used by cypress is http://127.0.0.1:30000<br>
>To run tests using another deployment:<br>
>`npm run cy:run -- --env meep_url="http://<Node IP>:<MEEP FE port>"`
# Run/Debug Cypress tests using GUI
cd js-apps/meep-frontend
npm run cy:open
>**NOTE**<br>
>Default AdvantEDGE URL used by cypress is http://127.0.0.1:30000<br>
>To run tests using another deployment:<br>
>`npm run cy:open -- --env meep_url="http://<Node IP>:<MEEP FE port>"`