Add tests to ensure we do not again have webapp regression: "Syntax-highlighting this file took too long." is not falling back to plaintext rendering mode
Created by: slimsag
When the syntax highlighter bails out because highlighting is taking too long (e.g. on large files or files it can't handle well for whatever reason), we always return a plaintext version of the document to be rendered.
However, it appears there has been a regression where the webapp / TS code is incorrectly ignoring the plaintext form it got instead of rendering it as it should be:
Reported by https://app.hubspot.com/contacts/2762526/company/407948923