comit-network / comit-js-sdk

JavaScript SDK for cnd's HTTP API written in TypeScript
Apache License 2.0
2 stars 3 forks source link

[Q1/Product] Improve SDK code quality and test coverage #92

Open bonomat opened 4 years ago

bonomat commented 4 years ago

Problem

In the last objective alignment meeting we agreed that we need to invest time and effort into improving the overall code quality of the comit-js-sdk.

Goal

The comit-js-sdk should be fully tested independently from comit-rs (i.e. outside of the e2e tests of comit-rs).

Recommendation

yosriady commented 4 years ago

Code coverage

Since you're already using Jest, you can generate code coverage by adding the flag --coverage. No additional setup needed. Jest can collect code coverage information from entire projects, including untested files.

Change https://github.com/comit-network/comit-js-sdk/blob/master/package.json#L12 to add jest --coverage

If you're using vscode, you can use a plugin to highlight you code which are uncovered.

yosriady commented 4 years ago

Static analysis

We should use https://eslint.org/.