python310Packages.gsd: disable on older Python releases

- add pythonImportsCheck
This commit is contained in:
Fabian Affolter 2022-11-06 18:55:48 +01:00 committed by GitHub
parent 86aeb9fc23
commit a8899fabff
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,27 +1,47 @@
{ lib, buildPythonPackage, fetchFromGitHub, isPy27
, cython, numpy
{ lib
, buildPythonPackage
, cython
, fetchFromGitHub
, numpy
, pytestCheckHook
, pythonOlder
}:
buildPythonPackage rec {
version = "2.6.1";
pname = "gsd";
disabled = isPy27;
version = "2.6.1";
format = "setuptools";
disabled = pythonOlder "3.7";
src = fetchFromGitHub {
owner = "glotzerlab";
repo = pname;
rev = "refs/tags/v${version}";
sha256 = "sha256-vQutfkSilfgRHuu/THWMG6bmkT1eKlAAniQM4DP8mqI=";
hash = "sha256-vQutfkSilfgRHuu/THWMG6bmkT1eKlAAniQM4DP8mqI=";
};
nativeBuildInputs = [ cython ];
propagatedBuildInputs = [ numpy ];
nativeBuildInputs = [
cython
];
propagatedBuildInputs = [
numpy
];
checkInputs = [
pytestCheckHook
];
pythonImportsCheck = [
"gsd"
];
checkInputs = [ pytestCheckHook ];
preCheck = ''
pushd gsd/test
'';
postCheck = ''
popd
'';
@ -30,6 +50,6 @@ buildPythonPackage rec {
description = "General simulation data file format";
homepage = "https://github.com/glotzerlab/gsd";
license = licenses.bsd2;
maintainers = [ maintainers.costrouc ];
maintainers = with maintainers; [ costrouc ];
};
}