(string: any, offset?: any, length?: any, encoding?: any)
| 2471 | } |
| 2472 | |
| 2473 | function testBufs(string: any, offset?: any, length?: any, encoding?: any) { |
| 2474 | bufReset() |
| 2475 | // @ts-ignore |
| 2476 | // eslint-disable-next-line prefer-spread, prefer-rest-params |
| 2477 | buf1.fill.apply(buf1, arguments) |
| 2478 | // @ts-ignore Swap bytes on BE archs for ucs2 encoding. |
| 2479 | // eslint-disable-next-line prefer-spread, prefer-rest-params |
| 2480 | assert.deepStrictEqual(buf1.fill.apply(buf1, arguments), writeToFill.apply(null, arguments)) |
| 2481 | } |
| 2482 | |
| 2483 | // Make sure these throw. |
| 2484 | assert.throws(() => Buffer.allocUnsafe(8).fill('a', -1)) |
no test coverage detected