(path, fileStructure)
| 66 | ]; |
| 67 | |
| 68 | function createFiles(path, fileStructure) { |
| 69 | for (const fileOrDir of fileStructure) { |
| 70 | if (typeof fileOrDir === 'string') { |
| 71 | fs.writeFileSync(pathModule.join(path, fileOrDir), ''); |
| 72 | } else { |
| 73 | const dirPath = pathModule.join(path, fileOrDir[0]); |
| 74 | fs.mkdirSync(dirPath); |
| 75 | createFiles(dirPath, fileOrDir[1]); |
| 76 | } |
| 77 | } |
| 78 | } |
| 79 | |
| 80 | // Make sure tmp directory is clean |
| 81 | tmpdir.refresh(); |
no test coverage detected
searching dependent graphs…