test: remove unnecessary `eslint-disable`

master
ikatyang 2017-09-03 22:06:55 +08:00
parent 3cc9083f1d
commit ca7be87f9e
23 changed files with 10 additions and 65 deletions

View File

@ -1,27 +1,21 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP // Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`boolean flags do not swallow the next argument 1`] = ` exports[`boolean flags do not swallow the next argument 1`] = `
"/* eslint-disable */ "console.log('could be single quote and without semi');
console.log('could be single quote and without semi');
" "
`; `;
exports[`boolean flags do not swallow the next argument 2`] = `""`; exports[`boolean flags do not swallow the next argument 2`] = `""`;
exports[`negated options work 1`] = ` exports[`negated options work 1`] = `
"/* eslint-disable */ "console.log(\\"could be single quote and without semi\\")
console.log(\\"could be single quote and without semi\\")
" "
`; `;
exports[`negated options work 2`] = `""`; exports[`negated options work 2`] = `""`;
exports[`unknown negated options are warned 1`] = ` exports[`unknown negated options are warned 1`] = `
"/* eslint-disable */ "console.log(\\"could be single quote and without semi\\");
console.log(\\"could be single quote and without semi\\");
" "
`; `;
@ -32,9 +26,7 @@ exports[`unknown negated options are warned 2`] = `
`; `;
exports[`unknown options are warned 1`] = ` exports[`unknown options are warned 1`] = `
"/* eslint-disable */ "console.log(\\"could be single quote and without semi\\");
console.log(\\"could be single quote and without semi\\");
" "
`; `;

View File

@ -1,20 +1,15 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP // Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`CLI overrides take precedence 1`] = ` exports[`CLI overrides take precedence 1`] = `
"/* eslint-disable */ "console.log(
console.log(
\\"should have semi\\" \\"should have semi\\"
); );
/* eslint-disable */
console.log( console.log(
\\"should not have semi\\" \\"should not have semi\\"
) )
/* eslint-disable */
console.log( console.log(
\\"should have semi\\" \\"should have semi\\"
); );
/* eslint-disable */
function f() { function f() {
console.log( console.log(
\\"should have tab width 8\\" \\"should have tab width 8\\"
@ -25,22 +20,16 @@ function f() {
module.exports = { module.exports = {
tabWidth: 8 tabWidth: 8
}; };
/* eslint-disable */
function f() { function f() {
console.log( console.log(
\\"should have no semicolons\\" \\"should have no semicolons\\"
) )
} }
/* eslint-disable */
function f() { function f() {
console.log( console.log(
\\"should have tab width 3\\" \\"should have tab width 3\\"
); );
} }
/* eslint-disable */
function f() { function f() {
console.log.apply( console.log.apply(
null, null,
@ -55,9 +44,7 @@ function f() {
`; `;
exports[`accepts configuration from --config 1`] = ` exports[`accepts configuration from --config 1`] = `
"/* eslint-disable */ "function f() {
function f() {
console.log(\\"should have tab width 8\\") console.log(\\"should have tab width 8\\")
} }
" "
@ -69,14 +56,9 @@ exports[`resolves configuration file with --find-config-path file 1`] = `
`; `;
exports[`resolves configuration from external files 1`] = ` exports[`resolves configuration from external files 1`] = `
"/* eslint-disable */ "console.log(\\"should have semi\\");
console.log(\\"should have semi\\");
/* eslint-disable */
console.log(\\"should not have semi\\") console.log(\\"should not have semi\\")
/* eslint-disable */
console.log(\\"should have semi\\"); console.log(\\"should have semi\\");
/* eslint-disable */
function f() { function f() {
console.log(\\"should have tab width 8\\"); console.log(\\"should have tab width 8\\");
} }
@ -85,18 +67,12 @@ function f() {
module.exports = { module.exports = {
tabWidth: 8 tabWidth: 8
}; };
/* eslint-disable */
function f() { function f() {
console.log(\\"should have no semicolons\\") console.log(\\"should have no semicolons\\")
} }
/* eslint-disable */
function f() { function f() {
console.log(\\"should have tab width 3\\"); console.log(\\"should have tab width 3\\");
} }
/* eslint-disable */
function f() { function f() {
console.log.apply(null, [ console.log.apply(null, [
'this file', 'this file',

View File

@ -10,7 +10,7 @@ exports[`do not write file with --write + invalid file 1`] = `
exports[`write file with --write + unformated file 1`] = ` exports[`write file with --write + unformated file 1`] = `
Array [ Array [
Object { Object {
"content": "var x = 1; // eslint-disable-line "content": "var x = 1;
", ",
"filename": "unformated.js", "filename": "unformated.js",
}, },

View File

@ -1,3 +1 @@
/* eslint-disable */
console.log("could be single quote and without semi") console.log("could be single quote and without semi")

View File

@ -1,2 +1 @@
/* eslint-disable */
console.log("should not have semi") console.log("should not have semi")

View File

@ -1,2 +1 @@
/* eslint-disable */
console.log("should have semi"); console.log("should have semi");

View File

@ -1,2 +1 @@
/* eslint-disable */
console.log("should have semi"); console.log("should have semi");

View File

@ -1,5 +1,3 @@
/* eslint-disable */
function f() { function f() {
console.log("should have tab width 8"); console.log("should have tab width 8");
} }

View File

@ -1,5 +1,3 @@
/* eslint-disable */
function f() { function f() {
console.log("should have no semicolons"); console.log("should have no semicolons");
} }

View File

@ -1,5 +1,3 @@
/* eslint-disable */
function f() { function f() {
console.log("should have tab width 3"); console.log("should have tab width 3");
} }

View File

@ -1,5 +1,3 @@
/* eslint-disable */
function f() { function f() {
console.log.apply(null, [ console.log.apply(null, [
"this file", "this file",

View File

@ -1,2 +1 @@
/* eslint-disable */
'use strict'; 'use strict';

View File

@ -1,2 +1 @@
/* eslint-disable */
'use strict'; 'use strict';

View File

@ -1,2 +1 @@
/* eslint-disable */
'use strict'; 'use strict';

View File

@ -1,2 +1 @@
/* eslint-disable */
'use strict'; 'use strict';

View File

@ -1,2 +1 @@
/* eslint-disable */
'use strict'; 'use strict';

View File

@ -1,2 +1 @@
/* eslint-disable */
'use strict'; 'use strict';

View File

@ -1,2 +1 @@
/* eslint-disable */
'use strict'; 'use strict';

View File

@ -1,2 +1 @@
/* eslint-disable */
'use strict'; 'use strict';

View File

@ -1,2 +1 @@
/* eslint-disable */
'use strict'; 'use strict';

View File

@ -1,2 +1 @@
/* eslint-disable */
'use strict'; 'use strict';

View File

@ -1 +1 @@
var x = 1; // eslint-disable-line var x = 1;

View File

@ -1 +1 @@
var x = 1; // eslint-disable-line var x = 1;