python312Packages.graphviz: fix tests with python3.12
This commit is contained in:
@@ -3,11 +3,13 @@
|
||||
, buildPythonPackage
|
||||
, pythonOlder
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, substituteAll
|
||||
, graphviz
|
||||
, xdg-utils
|
||||
, makeFontsConf
|
||||
, freefont_ttf
|
||||
, setuptools
|
||||
, mock
|
||||
, pytest
|
||||
, pytest-mock
|
||||
@@ -17,7 +19,7 @@
|
||||
buildPythonPackage rec {
|
||||
pname = "graphviz";
|
||||
version = "0.20.1";
|
||||
format = "setuptools";
|
||||
pyproject = true;
|
||||
|
||||
disabled = pythonOlder "3.7";
|
||||
|
||||
@@ -35,6 +37,12 @@ buildPythonPackage rec {
|
||||
inherit graphviz;
|
||||
xdgutils = xdg-utils;
|
||||
})
|
||||
# https://github.com/xflr6/graphviz/issues/209
|
||||
(fetchpatch {
|
||||
name = "fix-tests-with-python312.patch";
|
||||
url = "https://github.com/xflr6/graphviz/commit/5ce9fc5de4f2284baa27d7a8d68ab0885d032868.patch";
|
||||
hash = "sha256-jREPACSc4aoHY3G+39e8Axqajw4eeKkAeVu2s40v1nI=";
|
||||
})
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
@@ -46,6 +54,10 @@ buildPythonPackage rec {
|
||||
fontDirectories = [ freefont_ttf ];
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
setuptools
|
||||
];
|
||||
|
||||
nativeCheckInputs = [
|
||||
mock
|
||||
pytest
|
||||
|
||||
Reference in New Issue
Block a user