krz/hutch
an ios client for sourcehut
clone: git clone https://gitbay.org/krz/hutch.git
63d0491b161457913c938d620dc1f26f29c798a9
verified · cmc
author: Christian Cleberg <hello@cleberg.net> · 2026-07-16T00:22:12Z
HutchTests/ReadmeViewTests.swift | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) @@ -179,8 +179,11 @@ struct MarkdownRenderingTests { func markdownImageQueryStringPreservesAmpersands() { let html = processInline("") + // `&` is the correct encoding for `&` in an attribute value, so the + // failure mode to guard against is double-escaping, which would make the + // browser request a literal "&" in the query string. #expect(html.contains("metric=security_rating")) - #expect(!html.contains("amp;metric")) + #expect(!html.contains("&amp;")) #expect(html.contains("<img")) }