summaryrefslogtreecommitdiff
path: root/spec/frontend/content_editor/extensions/attachment_spec.js
diff options
context:
space:
mode:
Diffstat (limited to 'spec/frontend/content_editor/extensions/attachment_spec.js')
-rw-r--r--spec/frontend/content_editor/extensions/attachment_spec.js10
1 files changed, 5 insertions, 5 deletions
diff --git a/spec/frontend/content_editor/extensions/attachment_spec.js b/spec/frontend/content_editor/extensions/attachment_spec.js
index d528096be34..6b804b3b4c6 100644
--- a/spec/frontend/content_editor/extensions/attachment_spec.js
+++ b/spec/frontend/content_editor/extensions/attachment_spec.js
@@ -8,7 +8,7 @@ import Video from '~/content_editor/extensions/video';
import Link from '~/content_editor/extensions/link';
import Loading from '~/content_editor/extensions/loading';
import { VARIANT_DANGER } from '~/flash';
-import httpStatus from '~/lib/utils/http_status';
+import { HTTP_STATUS_INTERNAL_SERVER_ERROR, HTTP_STATUS_OK } from '~/lib/utils/http_status';
import eventHubFactory from '~/helpers/event_hub_factory';
import { createTestEditor, createDocBuilder } from '../test_utils';
import {
@@ -132,7 +132,7 @@ describe('content_editor/extensions/attachment', () => {
};
beforeEach(() => {
- mock.onPost().reply(httpStatus.OK, successResponse);
+ mock.onPost().reply(HTTP_STATUS_OK, successResponse);
});
it('inserts a media content with src set to the encoded content and uploading true', async () => {
@@ -167,7 +167,7 @@ describe('content_editor/extensions/attachment', () => {
describe('when uploading request fails', () => {
beforeEach(() => {
- mock.onPost().reply(httpStatus.INTERNAL_SERVER_ERROR);
+ mock.onPost().reply(HTTP_STATUS_INTERNAL_SERVER_ERROR);
});
it('resets the doc to original state', async () => {
@@ -209,7 +209,7 @@ describe('content_editor/extensions/attachment', () => {
};
beforeEach(() => {
- mock.onPost().reply(httpStatus.OK, successResponse);
+ mock.onPost().reply(HTTP_STATUS_OK, successResponse);
});
it('inserts a loading mark', async () => {
@@ -246,7 +246,7 @@ describe('content_editor/extensions/attachment', () => {
describe('when uploading request fails', () => {
beforeEach(() => {
- mock.onPost().reply(httpStatus.INTERNAL_SERVER_ERROR);
+ mock.onPost().reply(HTTP_STATUS_INTERNAL_SERVER_ERROR);
});
it('resets the doc to orginal state', async () => {