This project has a wiki, access it here:
Thanks to BrowserStack for providing an open-source account for testing & development!
Read more in our wiki:
Follow these steps:
npm install
npm start
kartlag.json
from https://okologiskegrunnkart.test.artsdatabanken.no/kartlag.json
. Save this file in the public
folder (there exists already a kartlag_preview.json
file).Unit tests in Økologiske Grunnkart use jest
and react testing library
.
Unit-tests are run with the following command: npm run test
.
Integration-tests can be run locally in each of the environments Økologiske Grunnkart uses: dev
(localhost), test
, and prod
.
Furthermore, integration-tests can be run locally in three different ways: interactive
, in the background
, and in parallel in the background
.
Run one of the following commands for interactive tests:
npm run open
npm run open:test
npm run open:prod
Run one of the following commands for tests in the background:
npm run e2e
npm run e2e:test
npm run e2e:prod
Integration tests are divided in three groups which can be run separatedly. It requires opening three consoles and running one test group in each of them. This can be easily automated by doing this operation in a script or .bat file. Please note that, even though tests can be run in parallel on a single machine this way, it may require a significant amount of resources. More info at https://docs.cypress.io/
.
npm run group1
, npm run group2
, npm run group3
npm run group1:test
, npm run group2:test
, npm run group3:test
npm run group1:prod
, npm run group2:prod
, npm run group3:prod
Slett wms-assistent/node_modules/eslint-config-react-app