Socket
Socket
Sign inDemoInstall

deep-equal-in-any-order

Package Overview
Dependencies
Maintainers
1
Versions
54
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

deep-equal-in-any-order - npm Package Compare versions

Comparing version 1.0.18 to 1.0.19

11

build/index.js

@@ -27,11 +27,14 @@ 'use strict';

const { Assertion } = chai;
utils.addMethod(Assertion.prototype, 'equalInAnyOrder', function equalInAnyOrder(b) {
utils.addMethod(Assertion.prototype, 'equalInAnyOrder', function equalInAnyOrder(b, m) {
const a = this.__flags.object;
const { negate } = this.__flags;
const { negate, message } = this.__flags;
const msg = m || message;
if (negate) {
new Assertion(sortDeep(a)).to.not.deep.equal(sortDeep(b));
new Assertion(sortDeep(a), msg).to.not.deep.equal(sortDeep(b));
} else {
new Assertion(sortDeep(a)).to.deep.equal(sortDeep(b));
new Assertion(sortDeep(a), msg).to.deep.equal(sortDeep(b));
}
});
};
{
"name": "deep-equal-in-any-order",
"version": "1.0.18",
"version": "1.0.19",
"description": "chai plugin to match objects and arrays deep equality with arrays (including nested ones) being in any order",

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

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