(name, args)
| 496 | await delay(25 * (attempt + 1)); |
| 497 | } |
| 498 | } |
| 499 | try { |
| 500 | await fs.writeFile(target, contents, encoding); |
| 501 | return; |
| 502 | } catch (error) { |
| 503 | if (lastError && !error.cause) |
| 504 | error.cause = lastError; |
| 505 | throw error; |
| 506 | } |
| 507 | } finally { |
| 508 | try { |
| 509 | await fs.rm(temp, { force: true }); |
| 510 | } catch {} |
| 511 | } |
| 512 | } |
| 513 | function stateValuesEqual(left, right) { |
| 514 | if (Object.is(left, right)) |
| 515 | return true; |
no test coverage detected