depot/third_party/nixpkgs/pkgs/development/python-modules/dependency-injector/default.nix
Default email 2ce89355c3 Project import generated by Copybara.
GitOrigin-RevId: 22a81aa5fc15b2d41b12f7160a71cd4a9f3c3fa1
2020-06-15 17:56:04 +02:00

32 lines
771 B
Nix

{ stdenv, buildPythonPackage, fetchPypi, isPy3k, six, unittest2 }:
let
testPath =
if isPy3k
then "test_*_py3.py"
else "test_*_py2_py3.py";
in
buildPythonPackage rec {
pname = "dependency-injector";
version = "3.15.6";
src = fetchPypi {
inherit pname version;
sha256 = "fcca1464f567d902983bff507b9e2e3fda0f932ee009e36f74ed5b8c348d17f4";
};
propagatedBuildInputs = [ six ];
checkInputs = [ unittest2 ];
checkPhase = ''
unit2 discover -s tests/unit -p "${testPath}"
'';
meta = with stdenv.lib; {
description = "Dependency injection microframework for Python";
homepage = "https://github.com/ets-labs/python-dependency-injector";
license = licenses.bsd3;
maintainers = with maintainers; [ gerschtli ];
};
}