[208] [57] PDF-Text-Prüfungen: Poppler in der CI installiert, fehlendes Poppler nie still grün (lokal übersprungen, CI rot); Anonymität zusätzlich über die an jsPDF übergebenen Zeichenketten

This commit is contained in:
Claude committed 2026-11-14 15:32:58 +00:00
1 parent 6c7562c351
commit ead1fbc5d2
10 files changed
+98 -20

No files matched your search

+3 -3
View File
@@ -10,7 +10,7 @@ import { createPosterMaster, posterTemplate } from "../model/posterTemplates";
import { buildAreaReport, buildAreaReportPdf } from "./areaReport";
import { buildPagesPdf, layoutPages, pdfBytes } from "./layoutPdf";
import { ensurePdfFonts, prepareSvgFonts, resolvePdfFamily, setPdfFont, setPdfFontLoader } from "./pdfFonts";
import { HAVE_POPPLER, pdfVisibleText, withPdfFile } from "./pdfText.testing";
import { RUN_POPPLER_TESTS, pdfVisibleText, withPdfFile } from "./pdfText.testing";
const SPECIAL = "Größe Ø 12 ± 3 m² m³ – „Bürgenstock“ ß Äöü";
const EMB = /\byes\s+(yes|no)\s+(yes|no)\s+\d+\s+\d+\s*$/; // Spalte „emb“ = yes
@@ -64,7 +64,7 @@ describe("PDF-Schriften", () => {
expect(root.getAttribute("font-family")).toBe("Inter");
});
it.runIf(HAVE_POPPLER)("Bericht-PDF: Schrift eingebettet, Sonderzeichen im Text", async () => {
it.runIf(RUN_POPPLER_TESTS)("Bericht-PDF: Schrift eingebettet, Sonderzeichen im Text", async () => {
const report = buildAreaReport(sampleProject, { areas: true });
report.title = SPECIAL;
const doc = await buildAreaReportPdf(report);
@@ -77,7 +77,7 @@ describe("PDF-Schriften", () => {
expect(pdfVisibleText(bytes).replace(/\s+/g, " ")).toContain(SPECIAL);
});
it.runIf(HAVE_POPPLER)("Blatt-PDF: Plakat-Kopfzeile in Inter, Sonderzeichen im Text", async () => {
it.runIf(RUN_POPPLER_TESTS)("Blatt-PDF: Plakat-Kopfzeile in Inter, Sonderzeichen im Text", async () => {
const master = createPosterMaster("m1", posterTemplate("poster-a1-landscape")!);
master.titleBlock = { projectName: SPECIAL, author: "Zoë Müller" };
const lay: Layout = { id: "l1", name: "Grundriss", paper: "a1", orientation: "landscape", masterId: "m1", viewports: [] };