Moved 'use strict' in index.js to global

Updated tests accordingly
This commit is contained in:
Sam Richard 2015-03-26 19:15:59 -04:00
parent 5f1812f623
commit 8bc76e15e6
2 changed files with 3 additions and 16 deletions

View file

@ -1,3 +1,5 @@
'use strict';
var gutil = require('gulp-util'); var gutil = require('gulp-util');
var through = require('through2'); var through = require('through2');
var assign = require('object-assign'); var assign = require('object-assign');
@ -11,8 +13,6 @@ var PLUGIN_NAME = 'gulp-sass';
// Main Gulp Sass function // Main Gulp Sass function
////////////////////////////// //////////////////////////////
var gulpSass = function gulpSass(options) { var gulpSass = function gulpSass(options) {
'use strict';
return through.obj(function(file, enc, cb) { return through.obj(function(file, enc, cb) {
var opts, var opts,
callback; callback;
@ -61,8 +61,6 @@ var gulpSass = function gulpSass(options) {
// Log errors nicely // Log errors nicely
////////////////////////////// //////////////////////////////
gulpSass.logError = function logError(error) { gulpSass.logError = function logError(error) {
'use strict';
gutil.log(gutil.colors.red('[gulp-sass] ') + error.message); gutil.log(gutil.colors.red('[gulp-sass] ') + error.message);
}; };

View file

@ -10,11 +10,6 @@ var report;
describe('code style guide', function() { describe('code style guide', function() {
it('index.js should follow our lint style guide', function(done) { it('index.js should follow our lint style guide', function(done) {
cli = new eslint.CLIEngine({
'rules': {
'strict': [ 2, 'function' ]
}
});
report = cli.executeOnFiles(['index.js']); report = cli.executeOnFiles(['index.js']);
if (report.errorCount > 0 || report.warningCount > 0) { if (report.errorCount > 0 || report.warningCount > 0) {
console.log(formatter(report.results)); 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) { 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']); report = cli.executeOnFiles(['test/main.js']);
if (report.errorCount > 0 || report.warningCount > 0) { if (report.errorCount > 0 || report.warningCount > 0) {
console.log(formatter(report.results)); 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) { it('test/lint.js should follow our lint style guide', function(done) {
cli = new eslint.CLIEngine({ cli = new eslint.CLIEngine({
'rules': { 'rules': {
'no-console': 0, 'no-console': 0
'strict': [ 2, 'global' ]
} }
}); });
report = cli.executeOnFiles(['test/lint.js']); report = cli.executeOnFiles(['test/lint.js']);