python310Packages.pyperf: 2.4.1 -> 2.5.0

This commit is contained in:
Theodore Ni 2022-11-19 12:28:23 -08:00
parent 698540f73f
commit f1a397de0c
No known key found for this signature in database
GPG key ID: 48B67583BDDD4474

View file

@ -1,38 +1,41 @@
{ lib { lib
, buildPythonPackage , buildPythonPackage
, fetchPypi , fetchPypi
, six , fetchpatch
, statistics
, pythonOlder , pythonOlder
, nose
, psutil , psutil
, contextlib2 , unittestCheckHook
, mock
, unittest2
, isPy27
, python
}: }:
buildPythonPackage rec { buildPythonPackage rec {
pname = "pyperf"; pname = "pyperf";
version = "2.4.1"; version = "2.5.0";
format = "setuptools";
disabled = pythonOlder "3.7";
src = fetchPypi { src = fetchPypi {
inherit pname version; inherit pname version;
sha256 = "sha256-OM9ekMVvkGqDIM6CpQv6kskCuTr/1y5NyBWAEV81WFM="; hash = "sha256-n9m+W1ciTmi1pbiPcSbxW2yGZ1c/YqCjn68U1v3ROQk=";
}; };
checkInputs = [ nose psutil ] ++ patches = [
lib.optionals isPy27 [ contextlib2 mock unittest2 ]; (fetchpatch {
propagatedBuildInputs = [ six ] ++ name = "fix-pythonpath-in-tests.patch";
lib.optionals (pythonOlder "3.4") [ statistics ]; url = "https://github.com/psf/pyperf/commit/d373c5e56c0257d2d7abd705b676bea25cf66566.patch";
hash = "sha256-2q1fTf+uU3qj3BG8P5otX4f7mSTnQxm4sfmmgIUuszA=";
})
];
# tests not included in pypi repository propagatedBuildInputs = [
doCheck = false; psutil
];
checkPhase = '' checkInputs = [
${python.interpreter} -m nose unittestCheckHook
''; ];
unittestFlagsArray = [ "-s" "pyperf/tests/" "-v" ];
meta = with lib; { meta = with lib; {
description = "Python module to generate and modify perf"; description = "Python module to generate and modify perf";