From 2b5eacfca4438b5df4c6b64818db1f77319825bb Mon Sep 17 00:00:00 2001 From: machinewrapped Date: Sat, 4 May 2024 10:19:36 +0200 Subject: [PATCH] Run unit tests in makedistro --- scripts/makedistro.bat | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/scripts/makedistro.bat b/scripts/makedistro.bat index b61b28e7..7e1a5141 100644 --- a/scripts/makedistro.bat +++ b/scripts/makedistro.bat @@ -6,4 +6,11 @@ pip install --upgrade -r requirements.txt pip install --upgrade openai pip install --upgrade google.generativeai pip install --upgrade anthropic + +python.exe tests/unit_tests.py +if %errorlevel% neq 0 ( + echo Unit tests failed. Exiting... + exit /b %errorlevel% +) + pyinstaller --noconfirm --additional-hooks-dir="PySubtitleHooks" --add-data "theme/*;theme/" --add-data "assets/*;assets/" --add-data "instructions*;instructions/" --add-data "LICENSE;." "scripts/gui-subtrans.py"