anoma / namada

Rust implementation of Namada, a Proof-of-Stake L1 for interchain asset-agnostic privacy
https://namada.net
GNU General Public License v3.0
2.4k stars 956 forks source link

Code coverage audit, rework to obtain coverage w/o large E2E tests #1497

Open cwgoes opened 1 year ago

cwgoes commented 1 year ago

A lot of our coverage is provided by two large E2E tests (MASP & ledger transactions), which should be mostly replaced with / supplanted by unit / prop tests with proper mocks so that we can reach sufficient coverage.

tzemanovic commented 1 year ago

to my knowledge make test-unit-coverage skips e2e

cwgoes commented 1 year ago

Hmm - in that case @batconjurer or @mariari can you clarify the concern here?

tzemanovic commented 1 year ago

I agree that MASP should have unit / integration / prop tests. There's nothing to catch issues in it besides e2e tests and the lack of these tests is being a serious issue for the more complex integrations

brentstone commented 7 months ago

@tzemanovic @batconjurer @Fraccaman how relevant is this issue still?

Fraccaman commented 7 months ago

I think coverage is still low especially for MASP.

tzemanovic commented 2 months ago

I went through coverage report from #3704: https://app.codecov.io/gh/anoma/namada/pull/3704/tree/crates

In our crates, the least coverage comes from sdk (14466 missed lines), node (6593 lines), ibc (2186), apps_lib (2011). I think we can improve the coverage a lot in these if we include integration tests, which should be possible (WIP in #3704).

Specific section that need attention: