mirror of
https://github.com/strapi/strapi.git
synced 2025-07-26 02:20:32 +00:00
fix errors
This commit is contained in:
parent
3523c1f7cf
commit
ac00451e43
@ -1,4 +1,4 @@
|
|||||||
import { errors } from '@strapi/utils';
|
import { AlreadyOnReleaseError } from '../../services/validation';
|
||||||
import releaseActionController from '../release-action';
|
import releaseActionController from '../release-action';
|
||||||
|
|
||||||
const mockSanitizedQueryRead = jest.fn().mockResolvedValue({});
|
const mockSanitizedQueryRead = jest.fn().mockResolvedValue({});
|
||||||
@ -143,7 +143,7 @@ describe('Release Action controller', () => {
|
|||||||
|
|
||||||
it('should count already added entries and dont throw an error', async () => {
|
it('should count already added entries and dont throw an error', async () => {
|
||||||
mockCreateAction.mockRejectedValue(
|
mockCreateAction.mockRejectedValue(
|
||||||
new errors.ValidationError(
|
new AlreadyOnReleaseError(
|
||||||
'Entry with id 1 and contentType api::contentTypeA.contentTypeA already exists in release with id 1'
|
'Entry with id 1 and contentType api::contentTypeA.contentTypeA already exists in release with id 1'
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import type Koa from 'koa';
|
import type Koa from 'koa';
|
||||||
|
|
||||||
import { mapAsync, errors } from '@strapi/utils';
|
import { mapAsync } from '@strapi/utils';
|
||||||
import {
|
import {
|
||||||
validateReleaseAction,
|
validateReleaseAction,
|
||||||
validateReleaseActionUpdateSchema,
|
validateReleaseActionUpdateSchema,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user