2017-09-05 11:16:41 +02:00
|
|
|
{ lib, stdenv, buildPythonPackage, fetchPypi, pytest, hypothesis, zope_interface
|
|
|
|
, pympler, coverage, six, clang }:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "attrs";
|
2018-06-12 18:46:58 +02:00
|
|
|
version = "18.1.0";
|
2017-09-05 11:16:41 +02:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2018-06-12 18:46:58 +02:00
|
|
|
sha256 = "e0d0eb91441a3b53dab4d9b743eafc1ac44476296a2053b6ca3af0b139faf87b";
|
2017-09-05 11:16:41 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
# macOS needs clang for testing
|
2017-12-30 12:58:00 +01:00
|
|
|
checkInputs = [
|
2017-09-05 11:16:41 +02:00
|
|
|
pytest hypothesis zope_interface pympler coverage six
|
|
|
|
] ++ lib.optionals (stdenv.isDarwin) [ clang ];
|
|
|
|
|
|
|
|
checkPhase = ''
|
|
|
|
py.test
|
|
|
|
'';
|
|
|
|
|
2017-12-30 12:58:00 +01:00
|
|
|
# To prevent infinite recursion with pytest
|
|
|
|
doCheck = false;
|
|
|
|
|
2017-09-05 11:16:41 +02:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Python attributes without boilerplate";
|
|
|
|
homepage = https://github.com/hynek/attrs;
|
|
|
|
license = licenses.mit;
|
|
|
|
};
|
|
|
|
}
|