summary refs log tree commit diff
path: root/pkgs/development/python-modules/pydocstyle/default.nix
blob: 39d9f9f9a23ddcdb0eac3aea4fb1d43866fbac71 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
{ lib, buildPythonPackage, fetchFromGitHub, isPy3k
, mock
, pytest
, pytestpep8
, snowballstemmer
}:

buildPythonPackage rec {
  pname = "pydocstyle";
  version = "4.0.1";
  disabled = !isPy3k;

  src = fetchFromGitHub {
    owner = "PyCQA";
    repo = pname;
    rev = version;
    sha256 = "1sr8d2fsfpam4f14v4als6g2v6s3n9h138vxlwhd6slb3ll14y4l";
  };

  propagatedBuildInputs = [ snowballstemmer ];

  checkInputs = [ pytest pytestpep8 mock ];

  checkPhase = ''
    # test_integration.py installs packages via pip
    py.test --pep8 --cache-clear -vv src/tests -k "not test_integration"
  '';

  meta = with lib; {
    description = "Python docstring style checker";
    homepage = https://github.com/PyCQA/pydocstyle/;
    license = licenses.mit;
    maintainers = with maintainers; [ dzabraev ];
  };
}