Nile plugin adding coverage reports for Cairo Smart Contracts.
Project description
nile-coverage
Nile plugin adding coverage reports for Cairo Smart Contracts.
Getting started
:warning: WARNING
This package requires cairo-lang >= 0.10.1. If you are using older versions, check this section before continuing.
Install the plugin inside the virtual environment of your Nile project:
(env): pip install nile-coverage
Nile automatically detecs installed plugins using python entry points feature. You should see the coverage command listed running nile
, and you can run the report with:
(env): nile coverage
For a full list of options run:
(env): nile coverage --help
Troubleshooting
1. Getting Nothing to report after tests have been run successfully.
This project requires Starknet >= 0.10.1. If you are using Starknet 0.10.0, check this guide.
2. Report doesn't catch execution when multiple threads are used with pytest-xdist.
In order to solve this, pass the --single-thread
option to the coverage command:
(env): nile coverage -s
3. How to run the coverage in a subset of the tests suite.
Mark tests in with pytest marks and use the --mark
argument to run a subset of tests:
(env): nile coverage -m unit
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for nile_coverage-0.1.0b8-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 49ed8b1a823a158bf0299e8a7d89c89978dd923d69d5cfbd0c459f579f52774a |
|
MD5 | d48c4b01a09c5f51f56443db9b03cb9a |
|
BLAKE2b-256 | 2b76a01b93cda3ba90a5921fe79fce857f4f5d24958daf43b89ddd113b02a1a0 |