()
| 162 | }) |
| 163 | |
| 164 | const asyncErrorFunction = function () { |
| 165 | return new Promise<void>((resolve, reject) => { |
| 166 | setTimeout(function () { |
| 167 | reject(EXPECTED_ERROR) |
| 168 | }, 100) |
| 169 | // tslint ask resolve must be called, |
| 170 | // so write a falsy value, so that it never called |
| 171 | if (+new Date() < 0) { |
| 172 | resolve() |
| 173 | } |
| 174 | }) |
| 175 | } |
| 176 | |
| 177 | bot.on('message', async () => { |
| 178 | await asyncErrorFunction() |
no outgoing calls
no test coverage detected
searching dependent graphs…