Skip to content

Fix PDF delivery test timeout#73

Open
hrtechifyed wants to merge 3 commits into
mainfrom
fix/pdf-wipe-loop
Open

Fix PDF delivery test timeout#73
hrtechifyed wants to merge 3 commits into
mainfrom
fix/pdf-wipe-loop

Conversation

@hrtechifyed

Copy link
Copy Markdown
Owner

Root cause

The browser delivery test uses a lightweight FakeJsPDF adapter that implements addPage() and getNumberOfPages() but not deletePage(). The acceptance report assembler trims old pages in a loop before rebuilding. Because the proxy returned a no-op function for the missing method, the page count never decreased and report generation remained stuck on “Building your advisory document”.

Fix

  • add a guarded deletePage() fallback only when neither the real jsPDF API nor its prototype provides one
  • decrement the lightweight adapter's numeric page counter so the final assembler can make progress
  • leave real jsPDF untouched

Validation

The Executive Assessment Tests workflow must pass before merge.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant