All generated headers from running tests are stored

This commit is contained in:
2025-11-25 09:01:02 +01:00
parent f24ab92fd6
commit 57abf181b9

View File

@@ -105,7 +105,10 @@ let failed_test_ctr = 0;
const failed_test_threshold = 10;
const base_path = `/tmp/tultemplategen_test_${new Date().toISOString()}`;
await fs.mkdir(base_path)
await fs.mkdir(base_path);
const header_path = `${base_path}/headers`
await fs.mkdir(header_path);
async function store_test_results(archive_path, stderr) {
await fs.writeFile(`${archive_path}/stderr`, stderr);
@@ -191,6 +194,8 @@ await iterate_steps(0, () => {}, async () => {
};
}
await fs.writeFile(`${header_path}/${test_ctr}.typ`, generate_template_header(output_steps));
let zip = await generate_zip(output_steps);
// console.log(" - saving archive...");
@@ -208,7 +213,6 @@ await iterate_steps(0, () => {}, async () => {
await fs.writeFile(`${archive_path}/inputs.json`, JSON.stringify(inputs));
await fs.writeFile(`${archive_path}/outputs.json`, JSON.stringify(outputs));
// console.log(" - extracting archive...");
if(make_promises.length < max_threads) {