fix(tests): resolve 13 failing unit tests

- Use dynamic APP_VERSION instead of hardcoded v1.3.6 in:
  test_template_helpers, test_health, test_page_controller
- Add unresolved_folders to EXPECTED_TABLES in database/init.py
- Fix shallow copy bug in test_serie_scanner.py episodeDict comparison
- Update test_schema_constants to expect 6 tables instead of 5
This commit is contained in:
2026-06-11 08:36:41 +02:00
parent 9d52ff0c45
commit 4731fd644a
7 changed files with 17 additions and 8 deletions

View File

@@ -180,6 +180,7 @@ class TestTemplateHelpers:
def test_get_base_context(self):
"""Test getting base context."""
from src.server.utils.template_helpers import get_base_context
from src.server.utils.version import APP_VERSION
mock_request = MagicMock(spec=Request)
context = get_base_context(mock_request, "Test Title")
@@ -187,7 +188,7 @@ class TestTemplateHelpers:
assert context["request"] == mock_request
assert context["title"] == "Test Title"
assert context["app_name"] == "Aniworld Download Manager"
assert context["version"] == "v1.3.6"
assert context["version"] == APP_VERSION
def test_get_base_context_default_title(self):
"""Test getting base context with default title."""