change flag to integration-testing and update notification service construction

This commit is contained in:
2025-02-19 11:15:11 -08:00
parent f1b9fb6824
commit 58bb8a1c32

View File

@@ -21,16 +21,17 @@ async function main() {
});
const repository = new UnoptimizedInMemoryRepository();
if (process.argv.length > 2 && process.argv[2] == "mocks") {
let notificationService: NotificationService;
if (process.argv.length > 2 && process.argv[2] == "integration-testing") {
await loadTestData(repository);
notificationService = new NotificationService(repository, false);
} else {
const repositoryDataUpdater = new TimedApiBasedRepositoryLoader(
repository
);
await repositoryDataUpdater.start();
notificationService = new NotificationService(repository);
}
const notificationService = new NotificationService(repository);
notificationService.reloadAPNsTokenIfTimePassed();
const { url } = await startStandaloneServer(server, {