From 94d87e4c1e70c328015b8667ce6a581c01e7fe43 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Tue, 24 Jul 2018 00:12:19 +0200 Subject: [PATCH] python: testresources: 0.2.7 -> 2.0.1 --- .../python-modules/testresources/default.nix | 26 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 16 +----------- 2 files changed, 27 insertions(+), 15 deletions(-) create mode 100644 pkgs/development/python-modules/testresources/default.nix diff --git a/pkgs/development/python-modules/testresources/default.nix b/pkgs/development/python-modules/testresources/default.nix new file mode 100644 index 000000000000..fa4fc0b1fedf --- /dev/null +++ b/pkgs/development/python-modules/testresources/default.nix @@ -0,0 +1,26 @@ +{ lib, buildPythonPackage, fetchPypi, python +, pbr, fixtures, testtools }: + +buildPythonPackage rec { + pname = "testresources"; + version = "2.0.1"; + + src = fetchPypi { + inherit pname version; + sha256 = "ee9d1982154a1e212d4e4bac6b610800bfb558e4fb853572a827bc14a96e4417"; + }; + + buildInputs = [ pbr ]; + + checkInputs = [ fixtures testtools ]; + + checkPhase = '' + ${python.interpreter} -m testtools.run discover + ''; + + meta = with lib; { + description = "Pyunit extension for managing expensive test resources"; + homepage = https://launchpad.net/testresources; + license = licenses.bsd2; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index fe42f0e5d27a..d073f19165a9 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -13788,21 +13788,7 @@ in { }; }; - testresources = buildPythonPackage rec { - name = "testresources-${version}"; - version = "0.2.7"; - - src = pkgs.fetchurl { - url = "mirror://pypi/t/testresources/${name}.tar.gz"; - sha256 = "0cbj3plbllyz42c4b5xxgwaa7mml54lakslrn4kkhinxhdri22md"; - }; - - meta = { - description = "Pyunit extension for managing expensive test resources"; - homepage = https://pypi.python.org/pypi/testresources/; - license = licenses.bsd2; - }; - }; + testresources = callPackage ../development/python-modules/testresources { }; testtools = callPackage ../development/python-modules/testtools { };