nixpkgs/pkgs/development/python-modules/pytest-benchmark/default.nix
Dmitry Kalinkin 159e4dc581
python310Packages.pytest-benchmark: 3.4.1 -> 4.0.0 (#211015)
* python310Packages.pytest-benchmark: 3.4.1 -> 4.0.0

* python310Packages.pytest-benchmark.src: `hash` instead of `sha256`

Co-authored-by: Robert Schütz <github@dotlambda.de>

Co-authored-by: Robert Schütz <github@dotlambda.de>
2023-01-18 12:27:46 +01:00

47 lines
853 B
Nix

{ lib
, buildPythonPackage
, fetchFromGitHub
, pathlib
, py-cpuinfo
, pytest
, pythonOlder
, statistics
}:
buildPythonPackage rec {
pname = "pytest-benchmark";
version = "4.0.0";
format = "setuptools";
src = fetchFromGitHub {
owner = "ionelmc";
repo = pname;
rev = "v${version}";
hash = "sha256-f9Ty4+5PycraxoLUSa9JFusV5Cot6bBWKfOGHZIRR3o=";
};
buildInputs = [
pytest
];
propagatedBuildInputs = [
py-cpuinfo
] ++ lib.optionals (pythonOlder "3.4") [
pathlib
statistics
];
# Circular dependency
doCheck = false;
pythonImportsCheck = [
"pytest_benchmark"
];
meta = with lib; {
description = "Pytest fixture for benchmarking code";
homepage = "https://github.com/ionelmc/pytest-benchmark";
license = licenses.bsd2;
maintainers = with maintainers; [ costrouc ];
};
}