test(server): pass numeric row ids to controllers and seed addons with booleans

Controllers read their path ids through the rowId pipe now, so unit tests that call a handler directly pass the number the pipe hands it. The e2e suites enable addons with true, the type of the entity's field. The realtime gateway test builds its book sockets through one helper instead of a second hand-built TripAccessService.
This commit is contained in:
Maurice
2026-11-18 13:36:37 +01:00
parent 26b220470a
commit bcc82db7bd
5 changed files with 41 additions and 37 deletions
+1 -1
View File
@@ -71,7 +71,7 @@ function not400(got: Answer[], error: string): Answer[] {
beforeAll(async () => {
app = await buildApp();
orm = app.get(MikroORM);
await updateRows(orm, Addons, {}, { enabled: 1 });
await updateRows(orm, Addons, {}, { enabled: true });
}, 60_000);
afterAll(async () => {
+1 -1
View File
@@ -223,7 +223,7 @@ describe('ROUTEID: every route answers a malformed path id like an unknown one',
orm = app.get(MikroORM);
await app.listen(0, '127.0.0.1');
baseUrl = `http://127.0.0.1:${(app.getHttpServer().address() as AddressInfo).port}`;
await updateRows(orm, Addons, {}, { enabled: 1 });
await updateRows(orm, Addons, {}, { enabled: true });
const { user: admin } = await makeAdmin(orm);
const { user: other } = await makeUser(orm);