bug fixes: subnets listing, icons resizing and some shenanigans

This commit is contained in:
Zakaria
2026-10-07 10:54:58 -04:00
parent 71c2d276b6
commit 0036ef7e51
9 changed files with 51 additions and 8 deletions
+11
View File
@@ -216,6 +216,17 @@ describe('PUT /instances/:id/security-groups', () => {
expect(res.status).toBe(200)
expect(receivedGroupIds).toEqual(['sg-123'])
})
test('rejects an empty selection', async () => {
const res = await app.request('/instances/i-test1/security-groups', {
method: 'PUT',
headers: {'content-type': 'application/json'},
body: JSON.stringify({groupIds: []}),
})
expect(res.status).toBe(400)
expect(await res.json()).toEqual({error: 'At least one security group is required'})
})
})
describe('POST /amis/:imageId/deregister', () => {