gulp-minify-css
Advanced tools
Comparing version 0.4.4 to 0.4.5
@@ -83,3 +83,3 @@ var path = require('path'), | ||
if (file.sourceMap) { | ||
opt.sourceMap = true; | ||
opt.sourceMap = JSON.stringify(file.sourceMap); | ||
} | ||
@@ -86,0 +86,0 @@ |
{ | ||
"name": "gulp-minify-css", | ||
"description": "Minify css with clean-css.", | ||
"version": "0.4.4", | ||
"version": "0.4.5", | ||
"repository": "https://github.com/jonathanepollack/gulp-minify-css.git", | ||
@@ -32,2 +32,3 @@ "homepage": "https://github.com/jonathanepollack/gulp-minify-css", | ||
"gulp-sourcemaps": "^1.3.0", | ||
"gulp-stylus": "^2.0.0", | ||
"mocha": "^1.21.4", | ||
@@ -34,0 +35,0 @@ "proxyquire": "^1.0.1" |
@@ -6,2 +6,3 @@ var gulp = require('gulp'), | ||
sourceMaps = require('gulp-sourcemaps'), | ||
stylus = require('gulp-stylus'), | ||
applySourceMap = require('vinyl-sourcemaps-apply'), | ||
@@ -23,3 +24,4 @@ gutil = require('gulp-util'), | ||
describe('with buffers and gulp-sourcemaps', function() { | ||
var filename = path.join(__dirname, './fixture/sourcemap.css'); | ||
var filename = path.join(__dirname, './fixture/sourcemap.css'), | ||
filenameStylus = path.join(__dirname, './fixture/sourcemap.styl'); | ||
@@ -70,3 +72,37 @@ it('should generate source map with correct mapping', function(done) { | ||
}); | ||
it('should generate source map with correct sources when using preprocessor (stylus) and gulp.src without base', function(done) { | ||
var write = sourceMaps.write(); | ||
write.on('data', function (file) { | ||
console.log(file.sourceMap.sources); | ||
expect(file.sourceMap).to.have.property('sources').with.length(2); | ||
done(); | ||
}); | ||
gulp.src(filenameStylus) | ||
.pipe(sourceMaps.init()) | ||
.pipe(stylus()) | ||
.pipe(minifyCSS(opts)) | ||
.pipe(write); | ||
}); | ||
it('should generate source map with correct sources when using preprocessor (stylus) and gulp.src with base', function(done) { | ||
var write = sourceMaps.write(); | ||
write.on('data', function (file) { | ||
console.log(file.sourceMap.sources); | ||
expect(file.sourceMap).to.have.property('sources').with.length(2); | ||
done(); | ||
}); | ||
gulp.src(filenameStylus, { | ||
base: '.' | ||
}) | ||
.pipe(sourceMaps.init()) | ||
.pipe(stylus()) | ||
.pipe(minifyCSS(opts)) | ||
.pipe(write); | ||
}); | ||
}); | ||
}); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
23354
16
507
7