3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/development/python-modules/namedlist/default.nix
Raphael Borun Das Gupta 638612dadf pythonPackages.namedlist: bitbucket -> gitlab.com
adapt meta.homepage, as upstream has moved to gitlab.com
2020-09-29 06:15:16 -07:00

34 lines
765 B
Nix

{ lib
, buildPythonPackage
, fetchPypi
, pytest
}:
buildPythonPackage rec {
pname = "namedlist";
version = "1.8";
src = fetchPypi {
inherit pname version;
sha256 = "34f89fc992592c80b39a709e136edcf41ea17f24ba31eaf84a314a02c8b9bcef";
};
# Test file has a `unittest.main()` at the bottom that fails the tests;
# py.test can run the tests without it.
postPatch = ''
substituteInPlace test/test_namedlist.py --replace "unittest.main()" ""
'';
checkInputs = [ pytest ];
checkPhase = ''
py.test
'';
meta = {
description = "Similar to namedtuple, but instances are mutable";
homepage = "https://gitlab.com/ericvsmith/namedlist";
license = lib.licenses.asl20;
maintainers = with lib.maintainers; [ ivan ];
};
}