diff --git a/api/src/chat/repositories/block.repository.spec.ts b/api/src/chat/repositories/block.repository.spec.ts index 7dc3c5cb..e37d7d62 100644 --- a/api/src/chat/repositories/block.repository.spec.ts +++ b/api/src/chat/repositories/block.repository.spec.ts @@ -169,7 +169,6 @@ describe('BlockRepository', () => { }); describe('prepareBlocksInCategoryUpdateScope', () => { - /******/ it('should update blocks within the scope based on category and ids', async () => { jest.spyOn(blockRepository, 'findOne').mockResolvedValue({ id: blockValidIds[0], @@ -211,7 +210,6 @@ describe('BlockRepository', () => { }); describe('prepareBlocksOutOfCategoryUpdateScope', () => { - /******/ it('should update blocks outside the scope by removing references from attachedBlock', async () => { const otherBlocks = [ { @@ -233,7 +231,6 @@ describe('BlockRepository', () => { }); }); - /******/ it('should update blocks outside the scope by removing references from nextBlocks', async () => { const otherBlocks = [ { @@ -256,7 +253,6 @@ describe('BlockRepository', () => { }); describe('preUpdateMany', () => { - /******/ it('should update blocks in and out of the scope', async () => { const mockFind = jest.spyOn(blockRepository, 'find').mockResolvedValue([ { diff --git a/api/src/utils/generics/base-repository.ts b/api/src/utils/generics/base-repository.ts index 550b6c90..523a42b9 100644 --- a/api/src/utils/generics/base-repository.ts +++ b/api/src/utils/generics/base-repository.ts @@ -515,7 +515,7 @@ export abstract class BaseRepository< const result = await this.executeOne(query, this.cls); if (!result) { - const errorMessage = `Unable to update ${this.cls.name}${typeof criteria === 'string' ? ` with ID ${criteria}` : ''}`; + const errorMessage = `Unable to update ${this.cls.name} with ${typeof criteria === 'string' ? 'ID' : 'criteria'} ${JSON.stringify(criteria)}`; throw new Error(errorMessage); } diff --git a/api/src/utils/test/errors/messages.ts b/api/src/utils/test/errors/messages.ts index 150f1c61..2ecc3aff 100644 --- a/api/src/utils/test/errors/messages.ts +++ b/api/src/utils/test/errors/messages.ts @@ -7,4 +7,4 @@ */ export const getUpdateOneError = (entity: string, id?: string) => - new Error(`Unable to update ${entity}${id ? ` with ID ${id}` : ''}`); + new Error(`Unable to update ${entity}${id ? ` with ID \"${id}\"` : ''}`);