Skip to content

Commit b825cd9

Browse files
committed
chore: putout: actions: lint ☘️
1 parent d474070 commit b825cd9

34 files changed

Lines changed: 70 additions & 0 deletions

File tree

packages/cli-cache/lib/is-changed.spec.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ test('putout: cli: cache files: is changed: isNodeModulesChanged: cannot find',
1212
};
1313

1414
const findUp = stub();
15+
1516
const result = await isNodeModulesChanged(fileCache, {
1617
findUp,
1718
});
@@ -45,6 +46,7 @@ test('putout: cli: cache files: is changed: isEslintChanged: cannot find', async
4546
};
4647

4748
const findUp = stub();
49+
4850
const result = await isEslintChanged(fileCache, {
4951
findUp,
5052
});

packages/cli-choose-formatter/lib/index.spec.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,7 @@ test('putout: cli: choose-formatter: getFormatters: formatter', async (t) => {
124124
];
125125

126126
const writeFile = stub();
127+
127128
const readFile = stub().returns(stringify({
128129
formatter: 'progress-bar',
129130
}));
@@ -151,6 +152,7 @@ test('putout: cli: choose-formatter: nothing chosen', async (t) => {
151152
];
152153

153154
const writeFile = stub();
155+
154156
const readFile = stub().returns(stringify({
155157
formatter: 'progress-bar',
156158
}));
@@ -170,6 +172,7 @@ test('putout: cli: choose-formatter: nothing chosen', async (t) => {
170172
test('putout: cli: choose-formatter: nothing chosen: not found', async (t) => {
171173
const findUp = stub();
172174
const writeFile = stub();
175+
173176
const dependencies = [
174177
'@putout/formatter-dump',
175178
'@putout/formatter-progress-bar',
@@ -195,6 +198,7 @@ test('putout: cli: choose-formatter: nothing chosen: not found', async (t) => {
195198
test('putout: cli: choose-formatter: user formatter', async (t) => {
196199
const findUp = stub().returns('x');
197200
const writeFile = stub();
201+
198202
const dependencies = [
199203
'@putout/formatter-dump',
200204
'@putout/formatter-progress-bar',

packages/compare/lib/vars/index.spec.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -500,6 +500,7 @@ test('putout: compare: vars: jsx: JSXText: switch', (t) => {
500500
};
501501

502502
const source = 'const a = <section><h1>hello</h1><h2>world</h2></section>';
503+
503504
const expected = montag`
504505
const a = (
505506
<section><h1>world</h1><h2>hello</h2></section>
@@ -599,6 +600,7 @@ test('putout: compare: vars: findVarsWays: jsx: tag: switch', (t) => {
599600
};
600601

601602
const source = 'const a = <html><head>My page title</head><body>X</body></html>';
603+
602604
const expected = montag`
603605
const a = (
604606
<html><body>My page title</body><head>X</head></html>
@@ -731,6 +733,7 @@ test('putout: compare: vars: `__a`', (t) => {
731733
};
732734

733735
const input = 'const x = `hello`';
736+
734737
const {code} = putout(input, {
735738
fixCount: 1,
736739
plugins: [{
@@ -920,6 +923,7 @@ test('putout: compare: vars: getTemplateValues: TSTypeParameters', (t) => {
920923
};
921924

922925
const input = 'function write<es, ax, di>() {}';
926+
923927
const {code} = putout(input, {
924928
printer: 'putout',
925929
isTS: true,
@@ -952,6 +956,7 @@ test('putout: compare: vars: getTemplateValues: __type_params', (t) => {
952956
};
953957

954958
const input = 'function write<di, ax, es>() {}';
959+
955960
const {code} = putout(input, {
956961
printer: 'putout',
957962
isTS: true,
@@ -1091,6 +1096,7 @@ test('putout: compare: vars: getTemplateValues: setValues: setRawValue: Number',
10911096
};
10921097

10931098
const input = `String(1)`;
1099+
10941100
const {code} = putout(input, {
10951101
plugins: [{
10961102
'apply-template-literal': plugin,

packages/engine-loader/lib/plugins/load-plugins-async.spec.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ test('@putout/engine-loader: loadPluginsAsync', async (t) => {
1010
});
1111

1212
const plugin = await import('@putout/plugin-remove-debugger');
13+
1314
const expected = [{
1415
msg: '',
1516
rule: 'remove-debugger',

packages/engine-loader/test/load-plugins.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -518,6 +518,7 @@ test('putout: loader: disabled rules in plugin: enable', (t) => {
518518
test('putout: loader: disabled rules in plugin: load', async (t) => {
519519
const source = `const {run} = require('madrun');\n`;
520520
const convert = await import('@putout/plugin-nodejs/convert-commonjs-to-esm');
521+
521522
const {code} = putout(source, {
522523
rules: {
523524
'nodejs/convert-commonjs-to-esm-require': 'on',

packages/engine-parser/test/parser.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -233,6 +233,7 @@ test('putout: parser: decorator-legacy', (t) => {
233233
test('putout: parser: jsx', async (t) => {
234234
const source = fixture.jsxTemplate;
235235
const babel = await import('../lib/parsers/babel/index.js');
236+
236237
const node = babel.parse(source, {
237238
isJSX: true,
238239
printer: 'babel',

packages/engine-reporter/lib/formatter/formatter.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ export const getFormatter = async (formatterOptional, exit, overrides = {}) => {
1616
} = overrides;
1717

1818
const [formatterName = 'none', formatterOptions] = maybeArray(formatterOptional);
19+
1920
const loadFormatter = createAsyncLoader('formatter', {
2021
simpleImport,
2122
});

packages/engine-reporter/lib/subscribe.spec.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ const {assign} = Object;
88
test('putout: engine-reporter: subscribe: keypress', async (t) => {
99
const worker = new EventEmitter();
1010
const isStop = stub();
11+
1112
const keypress = stub().returns({
1213
isStop,
1314
});
@@ -37,6 +38,7 @@ test('putout: engine-reporter: subscribe: keypress', async (t) => {
3738
test('putout: engine-reporter: subscribe: createReport', async (t) => {
3839
const worker = new EventEmitter();
3940
const isStop = stub();
41+
4042
const keypress = stub().returns({
4143
isStop,
4244
});
@@ -72,6 +74,7 @@ test('putout: engine-reporter: subscribe: createReport', async (t) => {
7274
test('putout: engine-reporter: subscribe: worker: message: progress', async (t) => {
7375
const worker = new EventEmitter();
7476
const isStop = stub();
77+
7578
const keypress = stub().returns({
7679
isStop,
7780
});
@@ -105,6 +108,7 @@ test('putout: engine-reporter: subscribe: worker: message: progress', async (t)
105108
test('putout: engine-reporter: subscribe: worker: message: progress: write', async (t) => {
106109
const worker = new EventEmitter();
107110
const isStop = stub();
111+
108112
const keypress = stub().returns({
109113
isStop,
110114
});
@@ -140,6 +144,7 @@ test('putout: engine-reporter: subscribe: worker: message: progress: write', asy
140144
test('putout: engine-reporter: subscribe: worker: message: progress: write: line', async (t) => {
141145
const worker = new EventEmitter();
142146
const isStop = stub();
147+
143148
const keypress = stub().returns({
144149
isStop,
145150
});
@@ -173,6 +178,7 @@ test('putout: engine-reporter: subscribe: worker: message: progress: write: line
173178
test('putout: engine-reporter: subscribe: worker: message', async (t) => {
174179
const worker = new EventEmitter();
175180
const isStop = stub();
181+
176182
const keypress = stub().returns({
177183
isStop,
178184
});

packages/engine-runner/test/exclude.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ test('putout: runner: traverse: exclude', (t) => {
1919
};
2020

2121
const input = `const x = y;\n`;
22+
2223
const {code} = putout(input, {
2324
runPlugins,
2425
plugins: [

packages/eslint/lib/get-eslint.spec.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ test('putout: eslint: get-eslint: config: putout', async (t) => {
1717
});
1818

1919
const lintText = stub().returns([]);
20+
2021
const ESLintOverride = stub().returns({
2122
calculateConfigForFile,
2223
lintText,
@@ -45,6 +46,7 @@ test('putout: eslint: get-eslint: config: putout', async (t) => {
4546
test('putout: eslint: get-eslint: config: putout: new', async (t) => {
4647
const calculateConfigForFile = stub().resolves({});
4748
const lintText = stub().returns([]);
49+
4850
const ESLintOverride = stub().returns({
4951
calculateConfigForFile,
5052
lintText,

0 commit comments

Comments
 (0)