Revision 41923c43
Added by Ondřej Pražák almost 5 years ago
webpack/assets/javascripts/react_app/components/Editor/__tests__/integration.test.js | ||
---|---|---|
import React from 'react';
|
||
|
||
import API from '../../../API';
|
||
import IntegrationTestHelper from '../../../common/IntegrationTestHelper';
|
||
|
||
import { editorOptions, serverRenderResponse } from '../Editor.fixtures';
|
||
import Editor, { reducers } from '../index';
|
||
import * as EditorActions from '../EditorActions';
|
||
|
||
jest.mock('../../../API');
|
||
|
||
describe('Editor integration test', () => {
|
||
it('should flow', () => {
|
||
API.get.mockImplementation(async () => serverRenderResponse);
|
||
jest
|
||
.spyOn(EditorActions, 'fetchTemplatePreview')
|
||
.mockImplementation(async () => serverRenderResponse);
|
||
|
||
const integrationTestHelper = new IntegrationTestHelper(reducers);
|
||
|
Also available in: Unified diff
Fixes #27577 - Fail test on console.error