Javascript API for building voter-facing election applications.
Install directly from Github into your Javascript project.
npm install @aion-dk/js-client
https://aion-dk.github.io/js-client/
$ bin/docker-build
$ bin/docker-sh
To run tests:
yarn run test
To run the tests in watch mode:
yarn run tdd
To record the responses
In the js-client go to walkthrough.test.ts and disable mocks by changing const USE_MOCK = true; -> false.
Uncomment // return await recordResponses(async function() { in returns a receipt test. Remember the closing brackets at the end of the test.
The recorded responses should be saved the test/replies/otp_flow-folder.
The folder can be copy pasted to the ionic-app-repo by replacing the folder tests/e2e/fixtures/otp_flow
To generate HTML documentation for external usage:
yarn run docs