summaryrefslogtreecommitdiff
path: root/CONTRIBUTING.rst
diff options
context:
space:
mode:
authorTristan Van Berkom <tristan.vanberkom@codethink.co.uk>2019-01-08 21:44:18 -0500
committerTristan Van Berkom <tristan.vanberkom@codethink.co.uk>2019-01-09 14:52:22 -0500
commitd364ad0227aa82681d92a1000fddad10ee45ea10 (patch)
treef3eb457a4d4721c70fb112e666ae7320b01a8d9c /CONTRIBUTING.rst
parentf29a099580cd311517701da4bd125fa83c193f66 (diff)
downloadbuildstream-d364ad0227aa82681d92a1000fddad10ee45ea10.tar.gz
CONTRIBUTING.rst: Updated to mention new `coverage` tox environment.
Also point out that it is possible to run test environments in parallel using the `detox` tool.
Diffstat (limited to 'CONTRIBUTING.rst')
-rw-r--r--CONTRIBUTING.rst20
1 files changed, 20 insertions, 0 deletions
diff --git a/CONTRIBUTING.rst b/CONTRIBUTING.rst
index 1e672adf1..595fc5389 100644
--- a/CONTRIBUTING.rst
+++ b/CONTRIBUTING.rst
@@ -1498,6 +1498,13 @@ option when running tox::
tox -e py37
+If you would like to test and lint at the same time, or if you do have multiple
+python versions installed and would like to test against multiple versions, then
+we recommend using `detox <https://github.com/tox-dev/detox>`_, just run it with
+the same arguments you would give `tox`::
+
+ detox -e lint,py36,py37
+
Linting is performed separately from testing. In order to run the linting step which
consists of running the ``pycodestyle`` and ``pylint`` tools, run the following::
@@ -1574,6 +1581,19 @@ can run ``tox`` with ``-r`` or ``--recreate`` option.
./setup.py test --addopts 'tests/frontend/buildtrack.py::test_build_track'
+Observing coverage
+~~~~~~~~~~~~~~~~~~
+Once you have run the tests using `tox` (or `detox`), some coverage reports will
+have been left behind.
+
+To view the coverage report of the last test run, simply run::
+
+ tox -e coverage
+
+This will collate any reports from separate python environments that may be
+under test before displaying the combined coverage.
+
+
Adding tests
~~~~~~~~~~~~
Tests are found in the tests subdirectory, inside of which