Skip to content

Commit dff62e2

Browse files
committed
test: fix test case.
1 parent 05cc255 commit dff62e2

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

test/create.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ it('github-corners test case', async () => {
8686
document: {},
8787
});
8888
expect(html.indexOf('<dark-mode style=') > 0).toBeTruthy();
89-
expect(html.indexOf('<github-corners target="__blank"') > 0).toBeTruthy();
89+
expect(html.indexOf('<a xlink:href="') > 0).toBeTruthy();
9090
expect(html.indexOf('max-width: 960px; margin: 0 auto 60px auto; padding: 8px') > 0).toBeTruthy();
9191
expect(html.indexOf('class="markdown-style"') > 0).toBeTruthy();
9292

@@ -95,7 +95,7 @@ it('github-corners test case', async () => {
9595
'github-corners': 'https://github.com/jaywcjlove/markdown-to-html-cli',
9696
document: undefined,
9797
});
98-
expect(html.indexOf('<github-corners target="__blank" position="fixed" z-index="999" href="https://github.com/jaywcjlove/markdown-to-html-cli"></github-corners>') > 0).toBeTruthy();
98+
expect(html.indexOf('<a xlink:href="https://github.com/jaywcjlove/markdown-to-html-cli"') > 0).toBeTruthy();
9999
expect(html.indexOf('https://github.com/jaywcjlove/markdown-to-html-cli') > -1).toBeTruthy();
100100

101101
html = create({

test/index.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ console.log = jest.fn();
1212
it('githubCorners test case', async () => {
1313
expect(githubCorners({ })).toBeUndefined();
1414
expect(githubCornersFork({ })).toBeUndefined();
15-
expect(Object.keys(githubCorners({ href: 'https://github.com/jaywcjlove/markdown-to-html-cli' }))).toEqual(expect.arrayContaining(["0", "1"]));
15+
expect(Object.keys(githubCorners({ href: 'https://github.com/jaywcjlove/markdown-to-html-cli' }))).toEqual(expect.arrayContaining(["0"]));
1616
});
1717

1818
it('copyElement test case', async () => {

0 commit comments

Comments
 (0)