1
0
mirror of synced 2026-01-03 15:05:54 -05:00
Files
docs/tests/rendering-fixtures/markdown.js
2023-03-17 16:19:44 +00:00

23 lines
787 B
JavaScript

import { getDOM } from '../helpers/e2etest.js'
describe('markdown rendering', () => {
test('markdown in intro', async () => {
const $ = await getDOM('/get-started/markdown/intro')
const html = $('[data-testid="lead"]').html()
expect(html).toMatch('<strong>Markdown</strong>')
expect(html).toMatch('<code>syntax</code>')
expect(html).toMatch('<em>GitHub</em>')
})
test('page with permission frontmatter', async () => {
const $ = await getDOM('/get-started/markdown/permissions')
const html = $('[data-testid="permissions-statement"]').html()
// part of the UI
expect(html).toMatch('Who can use this feature')
// Markdown
expect(html).toMatch('<strong>admin</strong>')
// Liquid
expect(html).toMatch('GitHub Pages site')
})
})