Skip to content

Commit bdf3bd4

Browse files
committed
Add test
1 parent f559cbd commit bdf3bd4

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

test/integration/render.test.js

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,16 @@ describe('render', function() {
118118
);
119119
});
120120

121+
test('loading', async function() {
122+
const output = window.marked(
123+
"![alt text](http://imageUrl ':loading=lazy')"
124+
);
125+
126+
expect(output).toMatchInlineSnapshot(
127+
`"<p><img src=\\"http://imageUrl\\" data-origin=\\"http://imageUrl\\" alt=\\"alt text\\" loading=\\"lazy\\" /></p>"`
128+
);
129+
});
130+
121131
test('id', async function() {
122132
const output = window.marked(
123133
"![alt text](http://imageUrl ':id=someCssID')"

0 commit comments

Comments
 (0)