New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

mock-fs

Package Overview
Dependencies
Maintainers
1
Versions
87
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mock-fs - npm Package Compare versions

Comparing version 4.4.1 to 4.4.2

11

changelog.md
# Change Log
## 4.4.2
* Throw if item content is invalid in config (thanks @mutantcornholio, see [#221][#221])
* Use const in readme (thanks @denar90, see [#222][#222])
## 4.4.1
* Document that tests are run on Node 8.x as well.
## 4.4.0

@@ -198,1 +207,3 @@

[#210]: https://github.com/tschaub/mock-fs/pull/210
[#221]: https://github.com/tschaub/mock-fs/pull/221
[#222]: https://github.com/tschaub/mock-fs/pull/222

2

lib/binding.js

@@ -253,3 +253,3 @@ 'use strict';

var name, i, ii;
for ((i = 0), (ii = parts.length); i < ii; ++i) {
for (i = 0, ii = parts.length; i < ii; ++i) {
name = parts[i];

@@ -256,0 +256,0 @@ while (item instanceof SymbolicLink) {

@@ -60,3 +60,3 @@ 'use strict';

var i, ii, name, candidate;
for ((i = 0), (ii = parts.length); i < ii; ++i) {
for (i = 0, ii = parts.length; i < ii; ++i) {
name = parts[i];

@@ -142,3 +142,3 @@ candidate = directory.getItem(name);

item = obj();
} else {
} else if (typeof obj === 'object') {
// directory with more to populate

@@ -149,2 +149,4 @@ item = new Directory();

}
} else {
throw new Error('Unsupported type: ' + typeof obj + ' of item ' + name);
}

@@ -182,3 +184,3 @@ /**

var i, ii, name, candidate;
for ((i = 0), (ii = parts.length - 1); i < ii; ++i) {
for (i = 0, ii = parts.length - 1; i < ii; ++i) {
name = parts[i];

@@ -185,0 +187,0 @@ candidate = directory.getItem(name);

{
"name": "mock-fs",
"description": "A configurable mock file system. You know, for testing.",
"version": "4.4.1",
"version": "4.4.2",
"main": "lib/index.js",

@@ -28,4 +28,4 @@ "homepage": "https://github.com/tschaub/mock-fs",

"scripts": {
"lint:fix": "eslint --fix benchmarks lib test",
"pretest": "eslint benchmarks lib test",
"lint": "eslint benchmarks lib test",
"pretest": "npm run lint",
"test": "mocha --recursive test",

@@ -36,8 +36,8 @@ "bench": "bench benchmarks"

"bench-it": "0.4.0",
"chai": "3.5.0",
"eslint": "^3.19.0",
"eslint-config-tschaub": "^7.0.0",
"mocha": "3.1.2",
"rimraf": "2.5.4",
"semver": "^5.3.0"
"chai": "^4.1.2",
"eslint": "^4.8.0",
"eslint-config-tschaub": "^8.0.0",
"mocha": "^4.0.1",
"rimraf": "^2.6.2",
"semver": "^5.4.1"
},

@@ -44,0 +44,0 @@ "eslintConfig": {

@@ -10,3 +10,3 @@ # `mock-fs`

```js
var mock = require('mock-fs');
const mock = require('mock-fs');

@@ -13,0 +13,0 @@ mock({

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