OpenSlides/integration
peb-adr 1467f2b529
Updated services (#6421)
Co-authored-by: Adrian Richter <adrian@intevation.de>
2022-05-16 17:36:36 +00:00
..
cypress Updated services (#6421) 2022-05-16 17:36:36 +00:00
Dockerfile Run cypress workflow without docker 2021-11-23 22:47:49 +01:00
README.md Integration tests using cypress 2021-09-16 17:16:51 +02:00
cypress-docker.json Run cypress workflow without docker 2021-11-23 22:47:49 +01:00
cypress.json Run cypress workflow without docker 2021-11-23 22:47:49 +01:00
docker-compose.yml Integration tests using cypress 2021-09-16 17:16:51 +02:00
package-lock.json Bump minimist from 1.2.5 to 1.2.6 in /integration (#6390) 2022-03-26 19:06:30 +01:00
package.json Run cypress workflow without docker 2021-11-23 22:47:49 +01:00
resource-config-docker.js Run cypress workflow without docker 2021-11-23 22:47:49 +01:00
resource-config.js Run cypress workflow without docker 2021-11-23 22:47:49 +01:00

README.md

Integration tests

To test the integration of our OpenSlides services we are using cypress. There are not too many of them, but they are sufficient tell that our services are properly integrated.

  • The client can be accessed
  • Authentication works (admin admin can be logged in)
  • The backend accepts requests (of some sort)
  • The auto update transmits data to the client

(this list is not exhaustive)

Writing tests and using cypress

To write and execute tests meaningfully, you will want to install cypress locally. Inside the /integration directory, execute

$ npm install
$ npm run cypress:open
(or `make cypress-open` from the main directory) 

The cypress runner will open using electron and executes the tests for you.

Run in docker and CI

Start OpenSlides (Usually in dev setup). From the main directory run

$ make run-dev

in the /integration just fire

$ docker-compose build
$ docker-compose up
(or `make cypress-docker` from the main directory)

Cypress will run dockered and report errors inside the CLI. Screenshots and videos of the tests can be found in the /integration/results folder.

You can streamline the whole process by using

$ make run-system-tests

From the main directory. This can take while, since the docker of OS4 has to be build first.