add logic to send notification based on a provided threshold

This commit is contained in:
2025-03-25 15:19:09 -07:00
parent 1f8d4bfbd4
commit fb49577cf6
3 changed files with 37 additions and 28 deletions

View File

@@ -2,7 +2,7 @@ import { describe, expect, it } from "@jest/globals";
import { generateMockSystems } from "../testHelpers/mockDataGenerators";
import { setupTestServerContext, setupTestServerHolder } from "../testHelpers/apolloTestServerHelpers";
import assert = require("node:assert");
import { ScheduledNotificationData } from "../../src/notifications/schedulers/ETANotificationScheduler";
import { NotificationSchedulingArguments } from "../../src/notifications/schedulers/ETANotificationScheduler";
import { addMockShuttleToRepository, addMockStopToRepository } from "../testHelpers/repositorySetupHelpers";
// See Apollo documentation for integration test guide
@@ -108,7 +108,7 @@ describe("QueryResolvers", () => {
const shuttle = await addMockShuttleToRepository(context.repository, "1");
const stop = await addMockStopToRepository(context.repository, "1")
const notification: ScheduledNotificationData = {
const notification: NotificationSchedulingArguments = {
shuttleId: shuttle.id,
stopId: stop.id,
deviceId: "1",