Skip to content

Commit

Permalink
Remove mkdirp
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolo-ribaudo committed Nov 9, 2020
1 parent 343295e commit 67334ae
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@
"eslint-plugin-prettier": "^3.0.0",
"husky": "^4.3.0",
"lint-staged": "^10.5.1",
"mkdirp": "^0.5.1",
"nyc": "^15.1.0",
"prettier": "^2.1.2",
"react": "^17.0.1",
Expand Down
6 changes: 4 additions & 2 deletions test/helpers/createTestDirectory.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
import path from "path";
import mkdirp from "mkdirp";
import fs from "fs";
import rimraf from "rimraf";

export default function createTestDirectory(baseDirectory, testTitle, cb) {
const directory = path.join(baseDirectory, escapeDirectory(testTitle));

rimraf(directory, err => {
if (err) return cb(err);
mkdirp(directory, mkdirErr => cb(mkdirErr, directory));
fs.mkdir(directory, { recursive: true }, mkdirErr =>
cb(mkdirErr, directory),
);
});
}

Expand Down

0 comments on commit 67334ae

Please sign in to comment.