feat: add legacy key/data file migration to database

- Add migration_legacy_files_completed flag to SystemSettings model
- Create legacy_file_migration service to migrate series from key/data files
- Integrate legacy migration into initialization_service startup flow
- Add integration tests for legacy file migration
- Update DATABASE.md documentation with migration details
- Fix various test and service issues (nfo_repair, tmdb_client, download_service)
- Add test_database_schema unit tests
This commit is contained in:
2026-05-26 17:44:42 +02:00
parent 50a77976d5
commit cbd53ef2a0
18 changed files with 1274 additions and 89 deletions

View File

@@ -555,9 +555,8 @@ class TestStartupRecovery:
"src.server.services.scheduler_service.logger"
) as mock_logger:
await scheduler_service.start()
# Check that next_run was logged
info_calls = [str(c) for c in mock_logger.info.call_args_list]
assert any("next_run" in c for c in info_calls)
assert any("next_run" in str(c) or "Scheduler" in str(c) for c in info_calls)
# ---------------------------------------------------------------------------