Skip to content

Read VerifyResult.Text with the configured encoding - #1892

Merged
SimonCropp merged 3 commits into
mainfrom
fix-verify-result-encoding
Aug 29, 2026
Merged

Read VerifyResult.Text with the configured encoding#1892
SimonCropp merged 3 commits into
mainfrom
fix-verify-result-encoding

Conversation

@SimonCropp

Copy link
Copy Markdown
Member

Text read the verified file with File.ReadAllText, which assumes UTF8, while the compare path deliberately reads the same file with VerifierSettings.Encoding so a BOM-less non-UTF8 UseEncoding round-trips.

With UseEncoding set to something like Windows-1252 the test passed but result.Text handed back content whose non-ASCII bytes had decoded to U+FFFD.

Text read the verified file with File.ReadAllText, which assumes UTF8, while the
compare path deliberately reads the same file with VerifierSettings.Encoding so
a BOM-less non-UTF8 UseEncoding round-trips.

With UseEncoding set to something like Windows-1252 the test passed but
result.Text handed back content whose non-ASCII bytes had decoded to U+FFFD.
@SimonCropp SimonCropp added this to the 33.0.0 milestone Aug 29, 2026
@SimonCropp
SimonCropp merged commit 9358598 into main Aug 29, 2026
3 of 5 checks passed
@SimonCropp
SimonCropp deleted the fix-verify-result-encoding branch August 29, 2026 12:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant