Socket
Socket
Sign inDemoInstall

folder-hash

Package Overview
Dependencies
Maintainers
1
Versions
24
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

folder-hash - npm Package Compare versions

Comparing version 2.1.1 to 2.1.2

examples/async-example.js

4

package.json
{
"name": "folder-hash",
"version": "2.1.1",
"version": "2.1.2",
"description": "Create a hash checksum over a folder and its content - its children and their content",

@@ -35,4 +35,4 @@ "main": "index.js",

"engines": {
"node": ">=7.0.0"
"node": ">=6.0.0"
}
}

@@ -146,3 +146,3 @@ const { Volume } = require('memfs'),

it('generates the same hash if only the name differs and ignoreRootName is set', async function () {
it('generates the same hash if only the name differs and ignoreRootName is set', function () {
const hashElement = prep(Volume.fromJSON({

@@ -154,6 +154,8 @@ 'abc.txt': 'awesome content',

const abc = await hashElement('abc.txt', options);
const def = await hashElement('def/ghi.js', options);
abc.hash.should.equal(def.hash);
return Promise.all([
hashElement('abc.txt', options),
hashElement('def/ghi.js', options)
]).then(function (hashes) {
return hashes[0].hash.should.equal(hashes[1].hash);
});
});

@@ -391,3 +393,3 @@ });

it('generates the same hash if the folders only differ in name and ignoreRootName is set', async function () {
it('generates the same hash if the folders only differ in name and ignoreRootName is set', function () {
const hashElement = prep(Volume.fromJSON({

@@ -405,7 +407,9 @@ 'abc/def/ghi': 'content of ghi',

const abc = await hashElement('abc', options);
const def = await hashElement('def', options);
abc.hash.should.equal(def.hash);
return Promise.all([
hashElement('abc', options),
hashElement('def', options)
]).then(function (hashes) {
return hashes[0].hash.should.equal(hashes[1].hash);
});
});
});
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