node-stringify
Advanced tools
Comparing version 0.0.11 to 0.0.12
@@ -11,3 +11,3 @@ var _ = require('underscore') | ||
if (_.isFunction(obj)) { | ||
return '(' + obj.toString() + ')'; | ||
return '(' + obj.toString() + ')' | ||
} | ||
@@ -14,0 +14,0 @@ |
{ | ||
"name": "node-stringify", | ||
"version": "0.0.11", | ||
"version": "0.0.12", | ||
"author": { | ||
@@ -5,0 +5,0 @@ "name": "Chiang Fu", |
@@ -24,3 +24,7 @@ var stringify = require('../node-stringify.js') | ||
it('should stringify a function', function () { | ||
expect(stringify(function (x, y, z) {})).toBe('(function (x, y, z) {})') | ||
expect(stringify(function (a, b) { return a + b })) | ||
.toBe('(function (a, b) { return a + b })') | ||
var fn = eval(stringify(function (a, b) { return a + b })) | ||
expect(fn(2, 5)).toBe(7) | ||
}) | ||
@@ -27,0 +31,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
4549
80
2