0
Fork 0
mirror of https://github.com/withastro/astro.git synced 2024-12-30 22:03:56 -05:00
astro/packages/markdown/remark/test/entities.test.js

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

19 lines
554 B
JavaScript
Raw Normal View History

import assert from 'node:assert/strict';
import { before, describe, it } from 'node:test';
import { createMarkdownProcessor } from '../dist/index.js';
describe('entities', async () => {
let processor;
before(async () => {
processor = await createMarkdownProcessor();
});
it('should not unescape entities in regular Markdown', async () => {
const markdown = `<i>This should NOT be italic</i>`;
const { code } = await processor.render(markdown);
assert.equal(code, `<p>&#x3C;i>This should NOT be italic&#x3C;/i></p>`);
});
});