mirror of
https://github.com/brendan-ch/project-inter-server.git
synced 2026-04-17 16:00:32 +00:00
add integration test setup for parking data
This commit is contained in:
@@ -3,9 +3,11 @@ import { ApolloServer } from "@apollo/server";
|
||||
import { startStandaloneServer } from "@apollo/server/standalone";
|
||||
import { MergedResolvers } from "./MergedResolvers";
|
||||
import { ServerContext } from "./ServerContext";
|
||||
import { loadShuttleTestData, supportedIntegrationTestSystems } from "./loaders/shuttle/loadShuttleTestData";
|
||||
import { loadShuttleTestData } from "./loaders/shuttle/loadShuttleTestData";
|
||||
import { InterchangeSystem, InterchangeSystemBuilderArguments } from "./entities/InterchangeSystem";
|
||||
import { ChapmanApiBasedParkingRepositoryLoader } from "./loaders/parking/ChapmanApiBasedParkingRepositoryLoader";
|
||||
import { supportedIntegrationTestSystems } from "./loaders/supportedIntegrationTestSystems";
|
||||
import { loadParkingTestData } from "./loaders/parking/loadParkingTestData";
|
||||
|
||||
const typeDefs = readFileSync("./schema.graphqls", "utf8");
|
||||
|
||||
@@ -37,6 +39,9 @@ async function main() {
|
||||
|
||||
// TODO: Have loading of different data for different systems in the future
|
||||
await loadShuttleTestData(system.shuttleRepository);
|
||||
if (system.parkingRepository) {
|
||||
await loadParkingTestData(system.parkingRepository);
|
||||
}
|
||||
|
||||
return system;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user