diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-09-01 10:13:49 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-09-01 10:13:49 +0300 |
commit | fb58d337f0b8b6f685c1e94a9327d8d12ebfbf81 (patch) | |
tree | a285b8beb8303a81a7af0db968822fa05595e529 /spec/frontend/ide | |
parent | 3333112d46dd179a55295ebed754544a97b49b7f (diff) |
Add latest changes from gitlab-org/gitlab@14-2-stable-ee
Diffstat (limited to 'spec/frontend/ide')
-rw-r--r-- | spec/frontend/ide/components/repo_editor_spec.js | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/spec/frontend/ide/components/repo_editor_spec.js b/spec/frontend/ide/components/repo_editor_spec.js index b2254de706c..47bcfb59a5f 100644 --- a/spec/frontend/ide/components/repo_editor_spec.js +++ b/spec/frontend/ide/components/repo_editor_spec.js @@ -24,6 +24,8 @@ import axios from '~/lib/utils/axios_utils'; import ContentViewer from '~/vue_shared/components/content_viewer/content_viewer.vue'; import { file } from '../helpers'; +const PREVIEW_MARKDOWN_PATH = '/foo/bar/preview_markdown'; + const defaultFileProps = { ...file('file.txt'), content: 'hello world', @@ -77,6 +79,7 @@ const prepareStore = (state, activeFile) => { entries: { [activeFile.path]: activeFile, }, + previewMarkdownPath: PREVIEW_MARKDOWN_PATH, }; const storeOptions = createStoreOptions(); return new Vuex.Store({ @@ -278,10 +281,10 @@ describe('RepoEditor', () => { async ({ activeFile, viewer, shouldHaveMarkdownExtension } = {}) => { await createComponent({ state: { viewer }, activeFile }); if (shouldHaveMarkdownExtension) { - expect(vm.editor.projectPath).toBe(vm.currentProjectId); + expect(vm.editor.previewMarkdownPath).toBe(PREVIEW_MARKDOWN_PATH); expect(vm.editor.togglePreview).toBeDefined(); } else { - expect(vm.editor.projectPath).toBeUndefined(); + expect(vm.editor.previewMarkdownPath).toBeUndefined(); expect(vm.editor.togglePreview).toBeUndefined(); } }, |