From 94c361c5928a7dfc2a750fd13aca58e5642149fd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 20 Mar 2021 20:46:47 +0100 Subject: [PATCH] pythonPackages.drf-yasg: use pythonImportsCheck --- .../python-modules/drf-yasg/default.nix | 33 +++++++++++++------ 1 file changed, 23 insertions(+), 10 deletions(-) diff --git a/pkgs/development/python-modules/drf-yasg/default.nix b/pkgs/development/python-modules/drf-yasg/default.nix index 3935119971b..ab1d551fea3 100644 --- a/pkgs/development/python-modules/drf-yasg/default.nix +++ b/pkgs/development/python-modules/drf-yasg/default.nix @@ -1,13 +1,15 @@ -{ - lib, - buildPythonPackage, - fetchPypi, - inflection, - ruamel_yaml, - setuptools_scm, - six, - coreapi, - djangorestframework, +{ lib +, buildPythonPackage +, fetchPypi +, inflection +, ruamel_yaml +, setuptools_scm +, six +, coreapi +, djangorestframework +, pytestCheckHook +, pytest-django +, datadiff }: buildPythonPackage rec { @@ -36,6 +38,17 @@ buildPythonPackage rec { djangorestframework ]; + checkInputs = [ + pytestCheckHook + pytest-django + datadiff + ]; + + # ImportError: No module named 'testproj.settings' + doCheck = false; + + pythonImportsCheck = [ "drf_yasg" ]; + meta = with lib; { description = "Generation of Swagger/OpenAPI schemas for Django REST Framework"; homepage = "https://github.com/axnsan12/drf-yasg";