lodash-contrib
Advanced tools
Comparing version 241.4.6 to 241.4.7
var fs = require('fs'); | ||
var vm = require('vm'); | ||
var path = require('path'); | ||
var _ = require('lodash').runInContext(); | ||
var isAddOnRegEx = _.bindAll(/^_\..+/, 'test'); | ||
var context = vm.createContext({_:_}); | ||
var context = vm.createContext({_: _}); | ||
var rightCurryVm = _.partialRight(vm.runInNewContext, context); | ||
function simpleReadFile(filename) { return fs.readFileSync(filename); } | ||
function simpleReadFile(filename) { | ||
return fs.readFileSync(path.join(__dirname, filename)); | ||
} | ||
_(fs.readdirSync(__dirname)).filter(isAddOnRegEx.test).map(simpleReadFile).each(function (code) { | ||
@@ -10,0 +13,0 @@ rightCurryVm(code); |
{ | ||
"name": "lodash-contrib", | ||
"description": "The brass buckles on lodash's utility belt", | ||
"version": "241.4.6", | ||
"version": "241.4.7", | ||
"main": "index.js", | ||
@@ -6,0 +6,0 @@ "dependencies": { |
@@ -44,4 +44,3 @@ | ||
var obj = {'foo&bar': 'baz', 'test': 'total success', 'nested': {'works': 'too'}, 'isn\'t': ['that', 'cool?']}; | ||
equal(_.toQuery(obj), 'foo%26bar=baz&test=total+success&nested%5Bworks%5D=too&isn\'t%5B%5D=that&isn\'t%5B%5D=cool%3F', 'can convert a hash to a query string'); | ||
equal(_.toQuery(obj), jQuery.param(obj), 'query serialization matchs jQuery.param()'); | ||
equal(_.toQuery(obj), 'foo%26bar=baz&test=total%20success&nested%5Bworks%5D=too&isn\'t%5B%5D=that&isn\'t%5B%5D=cool%3F', 'can convert a hash to a query string'); | ||
}); | ||
@@ -48,0 +47,0 @@ |
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
28993
1516898