refactor: user factories instead of stubs (#17540)

This commit is contained in:
Jason Rasmussen
2025-04-11 11:53:37 -04:00
committed by GitHub
parent 52d4b2fe57
commit 584e5894bf
17 changed files with 297 additions and 251 deletions

View File

@@ -54,7 +54,7 @@ describe(ApiKeyService.name, () => {
});
it('should throw an error if the api key does not have sufficient permissions', async () => {
const auth = factory.auth({ apiKey: factory.authApiKey({ permissions: [Permission.ASSET_READ] }) });
const auth = factory.auth({ apiKey: { permissions: [Permission.ASSET_READ] } });
await expect(sut.create(auth, { permissions: [Permission.ASSET_UPDATE] })).rejects.toBeInstanceOf(
BadRequestException,