MCPcopy Create free account
hub / github.com/porsager/postgres / exit

Function exit

deno/tests/test.js:63–87  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

61}
62
63function exit() {
64 let success = true
65 Object.values(tests).every((x) => {
66 if (x.succeeded)
67 return true
68
69 success = false
70 x.cleanup
71 ? console.error('⛔️', x.name + ' at line', x.line, 'cleanup failed', '\n', util.inspect(x.cleanup))
72 : console.error('⛔️', x.name + ' at line', x.line, x.failed
73 ? 'failed'
74 : 'never finished', x.error ? '\n' + util.inspect(x.error) : ''
75 )
76 })
77
78 only
79 ? console.error('⚠️', 'Not all tests were run')
80 : ignored
81 ? console.error('⚠️', ignored, 'ignored test' + (ignored === 1 ? '' : 's', '\n'))
82 : success
83 ? console.log('🎉')
84 : console.error('⚠️', 'Not good')
85
86 !process.exitCode && (!success || only || ignored) && (process.exitCode = 1)
87}
88

Callers 1

testFunction · 0.70

Calls 1

valuesMethod · 0.65

Tested by 1

testFunction · 0.56