Skip to content

Commit 32dc40a

Browse files
committed
test: putout: json: coverage
1 parent f3073ae commit 32dc40a

File tree

1 file changed

+28
-1
lines changed

1 file changed

+28
-1
lines changed

packages/putout/lib/lint/json.spec.mjs

Lines changed: 28 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,34 @@ test('putout: lint: json', (t) => {
2222
{
2323
"formatter": "json",
2424
"rules": {
25-
"remove-unused-variables": "off"
25+
"variables/remove-unused": "off"
26+
}
27+
}\n
28+
`;
29+
30+
t.equal(code, expected);
31+
t.end();
32+
});
33+
34+
test('putout: lint: json: same', (t) => {
35+
const rawSource = stringify({
36+
rules: {
37+
'remove-debugger': 'off',
38+
},
39+
formatter: 'json',
40+
});
41+
42+
const code = lintJSON(rawSource, {
43+
plugins: [
44+
'putout-config',
45+
],
46+
});
47+
48+
const expected = montag`
49+
{
50+
"formatter": "json",
51+
"rules": {
52+
"remove-debugger": "off"
2653
}
2754
}\n
2855
`;

0 commit comments

Comments
 (0)