summary refs log tree commit diff
path: root/pkgs/development/python-modules/pytest-benchmark/default.nix
blob: 0a361627e8e9879947f920603b79b4cefbf2acad (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
{ lib
, buildPythonPackage
, fetchFromGitHub
, pytestrunner
, pytest
, py-cpuinfo
, pythonOlder
, pathlib
, statistics
}:

buildPythonPackage rec {
  pname = "pytest-benchmark";
  version = "3.2.2";

  src = fetchFromGitHub {
    owner = "ionelmc";
    repo = pname;
    rev = "v${version}";
    sha256 = "1hslzzinpwc1zqhbpllqh3sllmiyk69pcycl7ahr0rz3micgwczj";
  };

  propagatedBuildInputs = [ pytest py-cpuinfo ] ++ lib.optional (pythonOlder "3.4") [ pathlib statistics ];

  meta = {
    description = "Py.test fixture for benchmarking code";
    homepage = https://github.com/ionelmc/pytest-benchmark;
    license = lib.licenses.bsd2;
    maintainers = with lib.maintainers; [ costrouc ];
  };
}