test: own soffice profile for the render-consistency leg

Run in parallel with lo-roundtrip, both soffice instances raced for
the shared user profile lock and the conversion died intermittently.
This commit is contained in:
Steffen Becker committed 2026-08-30 10:05:43 +00:00
1 parent 3f047efca8
commit dc06d88299
1 file changed
+2 -1
+2 -1
View File
@@ -24,7 +24,8 @@ function pgm(path: string): { w: number; h: number; pixels: Uint8Array } {
}
function renderPages(file: string, prefix: string): string[] {
execSync(`soffice --headless --convert-to pdf --outdir ${DIR}/${prefix} ${DIR}/${file}`, { stdio: 'pipe', timeout: 120000 });
// Own user profile: a parallel lo-roundtrip soffice would otherwise hold the lock.
execSync(`soffice -env:UserInstallation=file://${DIR}/profile --headless --convert-to pdf --outdir ${DIR}/${prefix} ${DIR}/${file}`, { stdio: 'pipe', timeout: 120000 });
const pdf = `${DIR}/${prefix}/${file.replace(/\.\w+$/, '.pdf')}`;
execSync(`pdftoppm -gray -r 60 ${pdf} ${DIR}/${prefix}/page`, { stdio: 'pipe', timeout: 120000 });
return readdirSync(`${DIR}/${prefix}`).filter((f) => f.endsWith('.pgm')).sort()