3
0
Fork 0
forked from mirrors/nixpkgs

python3Packages.Mako: add babel extra, disable lingua tests

This commit is contained in:
Martin Weinelt 2022-03-31 18:17:14 +02:00
parent fc4a13d81d
commit d26c2ee239

View file

@ -1,8 +1,16 @@
{ lib
, buildPythonPackage
, pythonOlder
, fetchPypi
, isPyPy
# propagates
, markupsafe
# extras: Babel
, Babel
# tests
, mock
, pytestCheckHook
}:
@ -11,13 +19,27 @@ buildPythonPackage rec {
pname = "Mako";
version = "1.2.0";
disabled = pythonOlder "3.7";
src = fetchPypi {
inherit pname version;
sha256 = "sha256-mnx+kiuH2zaGIQz0nV12cDOkHUAQsoTnR2gskr3dizk=";
};
propagatedBuildInputs = [ markupsafe ];
checkInputs = [ pytestCheckHook markupsafe mock ];
propagatedBuildInputs = [
markupsafe
];
passthru.extras-require = {
babel = [
Babel
];
};
checkInputs = [
pytestCheckHook
mock
] ++ passthru.extras-require.babel;
disabledTests = lib.optionals isPyPy [
# https://github.com/sqlalchemy/mako/issues/315
@ -29,6 +51,11 @@ buildPythonPackage rec {
"test_bytestring_passthru"
];
disabledTestPaths = [
# lingua dependency is not packaged
"test/ext/test_linguaplugin.py"
];
meta = with lib; {
description = "Super-fast templating language";
homepage = "https://www.makotemplates.org/";