MCPcopy Index your code
hub / github.com/codeceptjs/CodeceptJS / initFailMode

Function initFailMode

lib/plugin/pause.js:64–78  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

62}
63
64function initFailMode() {
65 let failed = false
66
67 event.dispatcher.on(event.test.started, () => {
68 failed = false
69 })
70
71 event.dispatcher.on(event.step.failed, () => {
72 failed = true
73 })
74
75 event.dispatcher.on(event.test.after, () => {
76 if (failed) pause()
77 })
78}
79
80function initTestMode() {
81 event.dispatcher.on(event.test.after, () => pause())

Callers 1

pause.jsFile · 0.85

Calls 1

pauseFunction · 0.85

Tested by

no test coverage detected