()
| 136 | }; |
| 137 | |
| 138 | const testRename = async () => { |
| 139 | await ran1.promise; |
| 140 | runs.push(currentRun); |
| 141 | currentRun = ''; |
| 142 | const fileToRenamePath = tmpdir.resolve(fileToUpdate); |
| 143 | const newFileNamePath = tmpdir.resolve(`test-renamed-${fileToUpdate}`); |
| 144 | |
| 145 | await performFileOperation( |
| 146 | () => renameSync(fileToRenamePath, newFileNamePath), |
| 147 | useRunApi, |
| 148 | ); |
| 149 | await ran2.promise; |
| 150 | |
| 151 | runs.push(currentRun); |
| 152 | child.kill(); |
| 153 | await once(child, 'exit'); |
| 154 | |
| 155 | assert.strictEqual(runs.length, 2); |
| 156 | |
| 157 | const [firstRun, secondRun] = runs; |
| 158 | assertTestOutput(firstRun, useRunApi); |
| 159 | |
| 160 | if (action === 'rename2') { |
| 161 | assert.match(secondRun, /MODULE_NOT_FOUND/); |
| 162 | return; |
| 163 | } |
| 164 | |
| 165 | assertTestOutput(secondRun, useRunApi); |
| 166 | }; |
| 167 | |
| 168 | const testDelete = async () => { |
| 169 | await ran1.promise; |
no test coverage detected
searching dependent graphs…