Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

gulp-minify-css

Package Overview
Dependencies
Maintainers
1
Versions
40
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

gulp-minify-css - npm Package Compare versions

Comparing version 0.4.4 to 0.4.5

test/fixture/sourcemap.styl

2

index.js

@@ -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);
});
});
});
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc