2021-01-25 08:26:54 +00:00
|
|
|
{ lib, buildPythonPackage, fetchPypi
|
2019-10-17 23:43:16 +01:00
|
|
|
, inflect
|
|
|
|
, jinja2
|
|
|
|
, jinja2_pluralize
|
|
|
|
, pygments
|
|
|
|
, six
|
|
|
|
# test dependencies
|
|
|
|
, coverage
|
|
|
|
, mock
|
|
|
|
, nose
|
|
|
|
, pycodestyle
|
|
|
|
, pyflakes
|
|
|
|
, pylint
|
|
|
|
, pytest
|
|
|
|
}:
|
2018-01-19 16:23:50 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "diff_cover";
|
2020-10-17 01:44:09 +01:00
|
|
|
version = "4.0.1";
|
2018-01-19 16:23:50 +00:00
|
|
|
|
|
|
|
preCheck = ''
|
|
|
|
export LC_ALL=en_US.UTF-8;
|
|
|
|
'';
|
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2020-10-17 01:44:09 +01:00
|
|
|
sha256 = "61a98ec126552d985c0e3e3c33cc72e79d7577f91f6edba99f635411a173d3b9";
|
2018-01-19 16:23:50 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [ jinja2 jinja2_pluralize pygments six inflect ];
|
|
|
|
|
2019-10-17 23:43:16 +01:00
|
|
|
checkInputs = [ mock coverage pytest nose pylint pyflakes pycodestyle ];
|
|
|
|
|
|
|
|
# ignore tests which try to write files
|
|
|
|
checkPhase = ''
|
|
|
|
pytest -k 'not added_file_pylint_console and not file_does_not_exist'
|
|
|
|
'';
|
2018-01-19 16:23:50 +00:00
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2018-01-19 16:23:50 +00:00
|
|
|
description = "Automatically find diff lines that need test coverage";
|
2020-04-13 10:27:33 +01:00
|
|
|
homepage = "https://github.com/Bachmann1234/diff-cover";
|
2018-01-19 16:23:50 +00:00
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = with maintainers; [ dzabraev ];
|
|
|
|
};
|
|
|
|
}
|