(filename, test, validation)
| 80 | } |
| 81 | |
| 82 | function formatValidation(filename, test, validation) { |
| 83 | const { $$lines: lines, name, code } = test; |
| 84 | |
| 85 | let output = ''; |
| 86 | for (const { |
| 87 | lines, |
| 88 | error: { message }, |
| 89 | } of validation) |
| 90 | output += `${lines ? lines[0] : '?'}:${message}\n`; |
| 91 | |
| 92 | return [ |
| 93 | `\x1b[31mINVALID:\x1b[0m ${filename}:${lines.start}`, |
| 94 | name, |
| 95 | code, |
| 96 | output, |
| 97 | ].join('\n\n'); |
| 98 | } |
| 99 | |
| 100 | (async () => { |
| 101 | const [filename, line] = process.argv.slice(2).join('').split(':'); |
no outgoing calls
no test coverage detected
searching dependent graphs…