* Stops current promise chain, calls `catch`. * Resets recorder to initial state. * * @api * @inner
()
| 88 | * @inner |
| 89 | */ |
| 90 | reset() { |
| 91 | if (promise && running) this.catch() |
| 92 | queueId++ |
| 93 | sessionId = null |
| 94 | sessionStack = [] // Clear the session stack |
| 95 | asyncErr = null |
| 96 | output.log(`${currentQueue()} Starting recording promises`) |
| 97 | promise = Promise.resolve() |
| 98 | oldPromises = [] |
| 99 | tasks = [] |
| 100 | ignoredErrs = [] |
| 101 | this.session.running = false |
| 102 | // reset this retries makes the retryFailedStep plugin won't work if there is Before/BeforeSuit block due to retries is undefined on Scenario |
| 103 | // this.retries = []; |
| 104 | }, |
| 105 | |
| 106 | /** |
| 107 | * @name CodeceptJS.recorder~session |
nothing calls this directly
no test coverage detected