Skip to content

Commit

Permalink
fix: test cases
Browse files Browse the repository at this point in the history
  • Loading branch information
ota-meshi committed Oct 21, 2023
1 parent c0783a5 commit 8e99e0a
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 25 deletions.
24 changes: 0 additions & 24 deletions test/integration/stylelint-vscode/__snapshots__/test.ts.snap
Original file line number Diff line number Diff line change
@@ -1,29 +1,5 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`StylelintRunner should be resolved with diagnostic plugin rule URL 1`] = `
Array [
Object {
"code": "scss/at-rule-no-unknown",
"codeDescription": Object {
"href": "https://github.com/stylelint-scss/stylelint-scss/blob/master/src/rules/at-rule-no-unknown",
},
"message": "Unexpected unknown at-rule \\"@unknown\\" (scss/at-rule-no-unknown)",
"range": Object {
"end": Object {
"character": 8,
"line": 0,
},
"start": Object {
"character": 0,
"line": 0,
},
},
"severity": 1,
"source": "Stylelint",
},
]
`;

exports[`StylelintRunner should be resolved with diagnostics when it lints CSS successfully 1`] = `
Array [
Object {
Expand Down
22 changes: 21 additions & 1 deletion test/integration/stylelint-vscode/test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -281,7 +281,27 @@ a { color: #000 }
},
);

expect(result.diagnostics).toMatchSnapshot();
expect(result.diagnostics).toEqual([
{
code: 'scss/at-rule-no-unknown',
codeDescription: {
href: 'https://github.com/stylelint-scss/stylelint-scss/blob/master/src/rules/at-rule-no-unknown',
},
message: 'Unexpected unknown at-rule "@unknown" (scss/at-rule-no-unknown)',
range: {
end: {
character: 8,
line: 0,
},
start: {
character: 0,
line: 0,
},
},
severity: 1,
source: 'Stylelint',
},
]);
});
}
});
Expand Down

0 comments on commit 8e99e0a

Please sign in to comment.