Moved 'use strict' in index.js to global
Updated tests accordingly
This commit is contained in:
parent
5f1812f623
commit
8bc76e15e6
6
index.js
6
index.js
|
@ -1,3 +1,5 @@
|
|||
'use strict';
|
||||
|
||||
var gutil = require('gulp-util');
|
||||
var through = require('through2');
|
||||
var assign = require('object-assign');
|
||||
|
@ -11,8 +13,6 @@ var PLUGIN_NAME = 'gulp-sass';
|
|||
// Main Gulp Sass function
|
||||
//////////////////////////////
|
||||
var gulpSass = function gulpSass(options) {
|
||||
'use strict';
|
||||
|
||||
return through.obj(function(file, enc, cb) {
|
||||
var opts,
|
||||
callback;
|
||||
|
@ -61,8 +61,6 @@ var gulpSass = function gulpSass(options) {
|
|||
// Log errors nicely
|
||||
//////////////////////////////
|
||||
gulpSass.logError = function logError(error) {
|
||||
'use strict';
|
||||
|
||||
gutil.log(gutil.colors.red('[gulp-sass] ') + error.message);
|
||||
};
|
||||
|
||||
|
|
13
test/lint.js
13
test/lint.js
|
@ -10,11 +10,6 @@ var report;
|
|||
|
||||
describe('code style guide', function() {
|
||||
it('index.js should follow our lint style guide', function(done) {
|
||||
cli = new eslint.CLIEngine({
|
||||
'rules': {
|
||||
'strict': [ 2, 'function' ]
|
||||
}
|
||||
});
|
||||
report = cli.executeOnFiles(['index.js']);
|
||||
if (report.errorCount > 0 || report.warningCount > 0) {
|
||||
console.log(formatter(report.results));
|
||||
|
@ -26,11 +21,6 @@ describe('code style guide', function() {
|
|||
});
|
||||
|
||||
it('test/main.js should follow our lint style guide', function(done) {
|
||||
cli = new eslint.CLIEngine({
|
||||
'rules': {
|
||||
'strict': [ 2, 'global' ]
|
||||
}
|
||||
});
|
||||
report = cli.executeOnFiles(['test/main.js']);
|
||||
if (report.errorCount > 0 || report.warningCount > 0) {
|
||||
console.log(formatter(report.results));
|
||||
|
@ -44,8 +34,7 @@ describe('code style guide', function() {
|
|||
it('test/lint.js should follow our lint style guide', function(done) {
|
||||
cli = new eslint.CLIEngine({
|
||||
'rules': {
|
||||
'no-console': 0,
|
||||
'strict': [ 2, 'global' ]
|
||||
'no-console': 0
|
||||
}
|
||||
});
|
||||
report = cli.executeOnFiles(['test/lint.js']);
|
||||
|
|
Loading…
Reference in a new issue