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

chai-builder

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

chai-builder - npm Package Compare versions

Comparing version 0.2.2 to 0.2.3

17

index.js

@@ -17,3 +17,3 @@ // Generated by CoffeeScript 1.8.0

return use = function(chai, utils) {
var Assertion, Expectation, assertionChainableMethods, assertionKeys, assertionProperties, chainCall, chainProperty;
var Assertion, Expectation, assertionChainableMethods, assertionPropertyNames, chainCall, chainProperty;
Assertion = chai.Assertion;

@@ -47,8 +47,8 @@ Expectation = (function() {

})();
assertionKeys = Object.keys(Assertion.prototype);
assertionProperties = Object.getOwnPropertyNames(Assertion.prototype);
assertionPropertyNames = Object.getOwnPropertyNames(Assertion.prototype);
assertionChainableMethods = Object.keys(Assertion.prototype.__methods);
assertionProperties.forEach(function(name) {
assertionPropertyNames.forEach(function(name) {
var descriptor;
if (assertionChainableMethods.indexOf(name) >= 0) {
return Object.defineProperty(Expectation.prototype, name, {
Object.defineProperty(Expectation.prototype, name, {
get: function() {

@@ -65,3 +65,6 @@ var next;

});
} else if (assertionKeys.indexOf(name) >= 0) {
return;
}
descriptor = Object.getOwnPropertyDescriptor(Assertion.prototype, name);
if (typeof descriptor.value === 'function') {
return Expectation.prototype[name] = function() {

@@ -72,3 +75,3 @@ var callArgs;

};
} else {
} else if (typeof descriptor.get === 'function') {
return Object.defineProperty(Expectation.prototype, name, {

@@ -75,0 +78,0 @@ get: function() {

{
"name": "chai-builder",
"version": "0.2.2",
"version": "0.2.3",
"description": "First class expressive expectations",

@@ -5,0 +5,0 @@ "main": "index.js",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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