mirror of
https://github.com/immich-app/immich
synced 2025-11-07 17:27:20 +00:00
refactor: validate enum (#19943)
This commit is contained in:
parent
68f249bc03
commit
351701c4d6
23 changed files with 161 additions and 225 deletions
|
|
@ -59,6 +59,13 @@ describe(APIKeyController.name, () => {
|
|||
expect(status).toBe(400);
|
||||
expect(body).toEqual(factory.responses.badRequest(['id must be a UUID']));
|
||||
});
|
||||
|
||||
it('should allow updating just the name', async () => {
|
||||
const { status } = await request(ctx.getHttpServer())
|
||||
.put(`/api-keys/${factory.uuid()}`)
|
||||
.send({ name: 'new name' });
|
||||
expect(status).toBe(200);
|
||||
});
|
||||
});
|
||||
|
||||
describe('DELETE /api-keys/:id', () => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue