Merge pull request #311162 from jemand771/fix-python3-chai

python312Packages.chai: fix python 3.12 build
This commit is contained in:
Weijia Wang 2024-05-13 00:02:40 +02:00 committed by GitHub
commit 836306cd7b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -10,6 +10,14 @@ buildPythonPackage rec {
sha256 = "ff8d2b6855f660cd23cd5ec79bd10264d39f24f6235773331b48e7fcd637d6cc";
};
postPatch = ''
# python 3.12 compatibility
substituteInPlace tests/*.py \
--replace "assertEquals" "assertEqual" \
--replace "assertNotEquals" "assertNotEqual" \
--replace "assert_equals" "assert_equal"
'';
meta = with lib; {
description = "Mocking, stubbing and spying framework for python";
};