mirror of
https://github.com/wahyd4/vuepress.git
synced 2026-08-09 05:16:23 +10:00
test($core): migrate test for markdown
This commit is contained in:
+1
-1
@@ -1,5 +1,5 @@
|
||||
import { Md, getFragment } from './util'
|
||||
import containers from '@/markdown/containers.js'
|
||||
import containers from '../../lib/markdown/containers.js'
|
||||
|
||||
const mdC = Md().use(containers)
|
||||
|
||||
+1
@@ -0,0 +1 @@
|
||||
<<< @/packages/@vuepress/core/__test__/markdown/fragments/snippet.js{1-3}
|
||||
+1
@@ -0,0 +1 @@
|
||||
<<< @/packages/@vuepress/core/__test__/markdown/fragments/snippet.js{1,3}
|
||||
@@ -0,0 +1 @@
|
||||
<<< @/packages/@vuepress/core/__test__/markdown/fragments/snippet.js
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
import { Md, getFragment } from './util'
|
||||
import highlight from '@/markdown/highlight.js'
|
||||
import highlight from '../../lib/markdown/highlight.js'
|
||||
|
||||
const md = Md()
|
||||
const mdH = Md().set({ highlight })
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
import { Md, getFragment } from './util'
|
||||
import highlightLines from '@/markdown/highlightLines.js'
|
||||
import highlightLines from '../../lib/markdown/highlightLines.js'
|
||||
|
||||
const md = Md()
|
||||
const mdH = Md().use(highlightLines)
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
import { Md, getFragment } from './util'
|
||||
import hoist from '@/markdown/hoist.js'
|
||||
import { dataReturnable } from '@/markdown/index.js'
|
||||
import hoist from '../../lib/markdown/hoist.js'
|
||||
import { dataReturnable } from '../../lib/markdown/index.js'
|
||||
|
||||
const md = Md().set({ html: true })
|
||||
const mdH = Md().set({ html: true }).use(hoist)
|
||||
+3
-3
@@ -1,7 +1,7 @@
|
||||
import { Md, getFragment } from './util'
|
||||
import preWrapper from '@/markdown/preWrapper.js'
|
||||
import lineNumbers from '@/markdown/lineNumbers.js'
|
||||
import highlightLines from '@/markdown/highlightLines.js'
|
||||
import preWrapper from '../../lib/markdown/preWrapper.js'
|
||||
import lineNumbers from '../../lib/markdown/lineNumbers.js'
|
||||
import highlightLines from '../../lib/markdown/highlightLines.js'
|
||||
|
||||
// lineNumbers must be chained after preWrapper.
|
||||
// since lineNumbers needs to add extra stateful class to its block wrapper.
|
||||
@@ -1,6 +1,6 @@
|
||||
import { Md } from './util'
|
||||
import link from '@/markdown/link.js'
|
||||
import { dataReturnable } from '@/markdown/index.js'
|
||||
import link from '../../lib/markdown/link.js'
|
||||
import { dataReturnable } from '../../lib/markdown/index.js'
|
||||
|
||||
const mdL = Md().use(link, {
|
||||
target: '_blank',
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
import { Md } from './util'
|
||||
import anchor from 'markdown-it-anchor'
|
||||
import slugify from '@/markdown/slugify.js'
|
||||
import slugify from '../../lib/markdown/slugify.js'
|
||||
|
||||
const mdS = Md().use(anchor, {
|
||||
slugify,
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
import { Md, getFragment } from './util'
|
||||
import snippet from '@/markdown/snippet.js'
|
||||
import highlightLines from '@/markdown/highlightLines.js'
|
||||
import snippet from '../../lib/markdown/snippet.js'
|
||||
import highlightLines from '../../lib/markdown/highlightLines.js'
|
||||
|
||||
const md = Md().use(snippet)
|
||||
const mdH = Md().use(snippet).use(highlightLines)
|
||||
@@ -15,18 +15,6 @@ module.exports = {
|
||||
'test.js',
|
||||
path.resolve(__dirname, '../test')
|
||||
],
|
||||
// projects: [
|
||||
// '<rootDir>/packages/@vuepress/*',
|
||||
// {
|
||||
// displayName: 'test',
|
||||
// verbose: true,
|
||||
// runner: 'jest',
|
||||
// testURL: 'http://localhost/',
|
||||
// testMatch: [
|
||||
// '<rootDir>/packages/@vuepress/*.js'
|
||||
// ]
|
||||
// }
|
||||
// ],
|
||||
moduleNameMapper: {
|
||||
'^@/(.*)$': '<rootDir>/$1'
|
||||
},
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
<<< @/test/markdown/fragments/snippet.js{1-3}
|
||||
@@ -1 +0,0 @@
|
||||
<<< @/test/markdown/fragments/snippet.js{1,3}
|
||||
@@ -1 +0,0 @@
|
||||
<<< @/test/markdown/fragments/snippet.js
|
||||
Reference in New Issue
Block a user