1

test: patch the interpreter instead of invoking python directly

This commit is contained in:
Motiejus Jakštys 2024-01-14 23:41:19 +02:00
parent 7007e9d5f6
commit 30a374ee03

View File

@ -43,6 +43,7 @@ stdenv.mkDerivation {
''; '';
passthru.tests.unit = passthru.tests.unit =
runCommand "e11sync-test" { runCommand "e11sync-test" {
src = self;
buildInputs = [ buildInputs = [
python3Packages.django_5 python3Packages.django_5
python3Packages.django-compressor python3Packages.django-compressor
@ -50,9 +51,11 @@ stdenv.mkDerivation {
dart-sass dart-sass
]; ];
} '' } ''
mkdir -p $out unpackPhase
cd ${self}/app patchShebangs --build $sourceRoot/app/manage.py
cd $sourceRoot
export GEOIP_PATH="${geoip-archive}" export GEOIP_PATH="${geoip-archive}"
${python3}/bin/python3 ./manage.py test app/manage.py test app
mkdir -p $out
''; '';
} }