about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/python-modules/luhn/default.nix
blob: 09ab90a3b177784657e03f5a0c17ccc49f6108e9 (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
36
{ lib
, buildPythonPackage
, fetchFromGitHub
, pytestCheckHook
}:

buildPythonPackage rec {
  pname = "luhn";
  version = "0.2.0";

  src = fetchFromGitHub {
    owner = "mmcloughlin";
    repo = pname;
    rev = version;
    sha256 = "sha256-ZifaCjOVhWdXuzi5n6V+6eVN5vrEHKgUdpSOXoMyR18=";
  };

  checkInputs = [
    pytestCheckHook
  ];

  pytestFlagsArray = [
    "test.py"
  ];

  pythonImportsCheck = [
    "luhn"
  ];

  meta = with lib; {
    description = "Python module for generate and verify Luhn check digits";
    homepage = "https://github.com/mmcloughlin/luhn";
    license = with licenses; [ mit ];
    maintainers = with maintainers; [ fab ];
  };
}