improve readme

This commit is contained in:
Sebastian 2022-04-25 15:38:45 -03:00
parent 0d81c22708
commit 1e6b2dd150
No known key found for this signature in database
GPG Key ID: BE4FF68352439FC1

62
README
View File

@ -3,18 +3,16 @@
This repository contains the implementation of a wallet for GNU Taler written
in TypeScript.
## Dependencies
The following dependencies are required to build the wallet:
* python>=3.8
* nodejs>=12
* jq
* npm
* pnpm
* zip
- python>=3.8
- nodejs>=12
- jq
- npm
- pnpm
- zip
## Installation
@ -44,7 +42,7 @@ packages/taler-wallet-webextension/extension/
```
We also provide a `Dockerfile` for a container that can build the
WebExtension. After you install docker, make sure the user is in group
WebExtension. After you install docker, make sure the user is in group
`docker` and (re-)start the docker daemon:
```shell
@ -93,27 +91,51 @@ Then, you can proceed with these instructions:
### Reviewing WebExtension UI examples
The WebExtension can be tested using Storybook. Using live server or building
static html files to deploy into nginx.
The WebExtension can be tested using example stories.
To run a live server use the 'dev-view' target
```shell
make webextension-dev-view
```
A server will start, usually at http://localhost:6006/.
On the left it will have a navigation panel with examples organized in a tree view.
Stories are defined with a *.stories.tsx file [1], you are free to create new or edit
Stories are defined with a \*.stories.tsx file [1], you are free to create new or edit
some and commit them in order to create a more complete set of examples.
[1] look for them at packages/taler-wallet-webextension/src/**/*.stories.tsx
[1] look for them at packages/taler-wallet-webextension/src/\*_/_.stories.tsx
### WebExtension UI Components
Every group of component have a directory and a README.
Testing component is based in two main category:
- UI testing
- State transition testing
For UI testing, every story example will be taken as a unit test.
For State testing, every stateful component should have an `useStateComponent` function that will be tested in a \*.test.ts file.
### Testing WebExtension
After building the WebExtension look for the folder `extension`
Inside you will find v2 and v3 version referring to the manifest version being used.
Firefox users:
- Go to about:addons
- Then `debug addon` (or about:debugging#/runtime/this-firefox)
- Then `Load temporary addon...`
- Select the `taler-wallet-webextension-*.zip`
Chrome users:
- Settings -> More tools -> Extensions (or go to chrome://extensions/)
- `Load unpacked` button in the upper left
- Selected the `unpacked` folder in v2 or v3
# Integration Tests
This repository comes with integration tests for GNU Taler. To run them,
install the wallet first. Then use the test runner from the
This repository comes with integration tests for GNU Taler. To run them,
install the wallet first. Then use the test runner from the
taler-integrationtests package:
```shell
@ -121,7 +143,7 @@ cd packages/taler-integrationtests/
./testrunner '*'
```
The test runner accepts a bash glob pattern as parameter. Individual tests can
The test runner accepts a bash glob pattern as parameter. Individual tests can
be run by specifying their name.
To check coverage, use nyc from the root of the repository and make sure that the taler-wallet-cli