-
Notifications
You must be signed in to change notification settings - Fork 60
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
23 changed files
with
295 additions
and
256 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -1,2 +1,30 @@ | |||
/node_modules | # Useless files | ||
/coverage | *.DS_Store | ||
|
|||
# Logs | |||
logs | |||
*.log | |||
|
|||
# Runtime data | |||
pids | |||
*.pid | |||
*.seed | |||
|
|||
# Directory for instrumented libs generated by jscoverage/JSCover | |||
lib-cov | |||
|
|||
# Coverage directory used by tools like istanbul | |||
coverage | |||
|
|||
# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files) | |||
.grunt | |||
|
|||
# node-waf configuration | |||
.lock-wscript | |||
|
|||
# Compiled binary addons (http://nodejs.org/api/addons.html) | |||
build/Release | |||
|
|||
# Dependency directory | |||
# https://www.npmjs.org/doc/misc/npm-faq.html#should-i-check-my-node_modules-folder-into-git- | |||
node_modules |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -1,8 +1,8 @@ | |||
module.exports = function(grunt) { | module.exports = function(grunt) { | ||
grunt.initConfig({ | grunt.initConfig({ | ||
pkg: grunt.file.readJSON('package.json') | pkg: grunt.file.readJSON("package.json") | ||
}); | }); | ||
grunt.loadNpmTasks('grunt-release'); | grunt.loadNpmTasks("grunt-release"); | ||
|
|
||
grunt.registerTask('default', []); | grunt.registerTask("default", []); | ||
}; | }; |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -1,12 +1,44 @@ | |||
"use strict"; | "use strict"; | ||
|
|
||
var istanbul = require("gulp-istanbul"); | |||
var mocha = require("gulp-mocha"); | var mocha = require("gulp-mocha"); | ||
|
|
||
var testSrc = "test/**/test_*.js"; | |||
|
|||
module.exports = function(gulp, depends) { | module.exports = function(gulp, depends) { | ||
gulp.task("test", depends, function() { | function runTests() { | ||
return gulp.src([ | return gulp.src(testSrc, { | ||
"test/**/test_*.js" | read: false | ||
], {read: false}) | }) | ||
.pipe(mocha({reporter: "spec"})); | .pipe(mocha({ | ||
reporter: "spec" | |||
})); | |||
} | |||
|
|||
gulp.task("test", depends, function (cb) { | |||
gulp.src(["*.js", "lib/**/*.js", "test/*.js"]) | |||
.pipe(istanbul()) // Covering files | |||
.pipe(istanbul.hookRequire()) // Force `require` to return covered files | |||
.on("finish", function () { | |||
runTests() | |||
.pipe(istanbul.writeReports()) // Creating the reports after tests runned | |||
.pipe(istanbul.enforceThresholds({ | |||
thresholds: { | |||
global: { | |||
statements: 95.05, | |||
branches: 86.64, | |||
functions: 97.14, | |||
lines: 95.05 | |||
} | |||
} | |||
})) | |||
.on("end", cb) | |||
.on("error", function(e) { | |||
console.error(e.toString()); | |||
process.exit(1); | |||
}); | |||
}); | |||
}); | }); | ||
|
|||
gulp.task("test:uncovered", depends, runTests); | |||
}; | }; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -1,12 +1,12 @@ | |||
"use strict"; | "use strict"; | ||
|
|
||
var hash = require("./util/hash"); | var merge = require("lodash.merge"); | ||
|
|
||
module.exports = function(eyeglass, sass) { | module.exports = function(eyeglass, sass) { | ||
var functions = {}; | return ["asset_url", "version"].reduce(function(functions, name) { | ||
["asset_url", "version"].forEach(function(name) { | return merge( | ||
var fn = require("./functions/" + name)(eyeglass, sass); | functions, | ||
hash.merge(functions, fn); | require("./functions/" + name)(eyeglass, sass) | ||
}); | ); | ||
return functions; | }, {}); | ||
}; | }; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.