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

unexpected

Package Overview
Dependencies
Maintainers
2
Versions
330
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

unexpected - npm Package Compare versions

Comparing version 5.0.0-beta13 to 5.0.0-beta14

2

lib/assertions.js

@@ -615,3 +615,3 @@ var utils = require('./utils');

} else if (!keyDiff || (keyDiff && !keyDiff.inline)) {
annotation.error(conflicting.label || 'should satisfy').error(':').sp()
annotation.error(conflicting.label || 'should satisfy').sp()
.block(inspect(value[key]));

@@ -618,0 +618,0 @@

@@ -38,3 +38,3 @@ var utils = require('./utils');

this.append(inspect(actual)).sp().annotationBlock(function () {
this.error('should be: ').block(inspect(expected));
this.error('should be ').block(inspect(expected));
if (comparison) {

@@ -209,3 +209,3 @@ this.nl().append(comparison.diff);

if (!keyDiff || (keyDiff && !keyDiff.inline)) {
annotation.error('should be: ')
annotation.error('should be ')
.block(inspect(expected[key]));

@@ -471,3 +471,3 @@

this.annotationBlock(function () {
this.error('missing: ').block(inspect(diffItem.value));
this.error('missing ').block(inspect(diffItem.value));
});

@@ -484,3 +484,3 @@ } else if (type === 'remove') {

this.block(inspect(diffItem.value).text(last ? ' ' : ', ')).annotationBlock(function () {
this.error('should be: ').block(inspect(diffItem.expected)).nl()
this.error('should be ').block(inspect(diffItem.expected)).nl()
.append(valueDiff.diff);

@@ -490,3 +490,3 @@ });

this.block(inspect(diffItem.value).text(last ? ' ' : ', ')).annotationBlock(function () {
this.error('should be: ').block(inspect(diffItem.expected));
this.error('should be ').block(inspect(diffItem.expected));
});

@@ -716,9 +716,13 @@ }

},
diffLimit: 512,
diff: function (actual, expected, output, diff, inspect) {
var result = {
diff: utils.diffStrings(this.hexDump(actual), this.hexDump(expected), output, {type: 'Chars', markUpSpecialCharacters: false})
};
result.diff.replaceText(/[\x00-\x1f\x7f-\xff␊␍]/g, '.').replaceText(/[│ ]/g, function (styles, content) {
this.text(content);
});
var result = {diff: output};
if (Math.max(actual.length, expected.length) > this.diffLimit) {
result.diff.comment('Diff suppressed due to size > ' + this.diffLimit);
} else {
result.diff = utils.diffStrings(this.hexDump(actual), this.hexDump(expected), output, {type: 'Chars', markUpSpecialCharacters: false})
.replaceText(/[\x00-\x1f\x7f-\xff␊␍]/g, '.').replaceText(/[│ ]/g, function (styles, content) {
this.text(content);
});
}
return result;

@@ -725,0 +729,0 @@ }

{
"name": "unexpected",
"version": "5.0.0-beta13",
"version": "5.0.0-beta14",
"author": "Sune Sloth Simonsen <sune@we-knowhow.dk>",

@@ -5,0 +5,0 @@ "keywords": [

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

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