(title, sql)
| 31 | const db = new DatabaseSync(dbPath, { readOnly: true }); |
| 32 | |
| 33 | function dump(title, sql) { |
| 34 | const rows = db.prepare(sql).all(); |
| 35 | const lines = rows.map((r) => JSON.stringify(r)).sort(); |
| 36 | process.stdout.write(`== ${title} (${lines.length})\n`); |
| 37 | for (const l of lines) process.stdout.write(l + '\n'); |
| 38 | } |
| 39 | |
| 40 | dump( |
| 41 | 'nodes', |
no test coverage detected