python310Packages.swagger-spec-validator: switch to pytestCheckHook, add imports check

This commit is contained in:
Sandro Jäckel 2022-05-30 04:49:22 +02:00
parent 260ed44242
commit 3f2838e5f5
No known key found for this signature in database
GPG key ID: 3AF5A43A3EECC2E5

View file

@ -1,4 +1,4 @@
{ lib, buildPythonPackage, fetchFromGitHub, pyyaml, jsonschema, six, pytest, mock }:
{ lib, buildPythonPackage, fetchFromGitHub, pyyaml, jsonschema, six, pytestCheckHook, mock }:
buildPythonPackage rec {
pname = "swagger-spec-validator";
@ -7,25 +7,23 @@ buildPythonPackage rec {
src = fetchFromGitHub {
owner = "Yelp";
repo = "swagger_spec_validator";
rev = "v" + version;
rev = "v${version}";
sha256 = "sha256-7+kFmtzeze0QlGf6z/M4J4F7z771a5NWewB1S3+bxn4=";
};
checkInputs = [
pytest
mock
];
checkPhase = ''
pytest tests
'';
propagatedBuildInputs = [
pyyaml
jsonschema
six
];
checkInputs = [
pytestCheckHook
mock
];
pythonImportsCheck = [ "swagger_spec_validator" ];
meta = with lib; {
homepage = "https://github.com/Yelp/swagger_spec_validator";
license = licenses.asl20;
@ -33,5 +31,3 @@ buildPythonPackage rec {
maintainers = with maintainers; [ vanschelven ];
};
}