Add TestTools with the nugetfuzz and decompdiff corpus tools - #4020
Open
siegfriedpammer wants to merge 2 commits into
Open
Add TestTools with the nugetfuzz and decompdiff corpus tools#4020siegfriedpammer wants to merge 2 commits into
siegfriedpammer wants to merge 2 commits into
Conversation
Both tools have found real decompiler defects (several merged fixes came out of nugetfuzz sweeps), but they only existed in a private checkout, so nobody else could run them and their setup knowledge lived in one head. They complement the fixture suite from the other side: it decompiles code we wrote, these decompile what the world ships. They stay outside the solution - file-based apps, run by hand, never by CI - and the near-empty Directory.Build.props/Directory.Packages.props keep the repo-wide warnings-as-errors, lock-file and central-package-management settings from reaching them. The catalog sweep driver is PowerShell rather than bash so it runs on Windows as well, which also drops its curl/jq dependency; staging falls back to copying when Windows withholds symlink privileges, and report file names are hash-truncated to stay inside the 260-character path limit. Assisted-by: Claude:claude-opus-5[1m]:Claude Code
A stalled request to nuget.org travelled out of the package run as an unhandled exception, so the report filed it as a decompiler [EXCEPTION] - the one bucket that has to hold nothing but real crashes - and the package was skipped without a single type being decompiled. Seen in the 2026-08-16 sweep, where common.logging.log4net timed out resolving its version list and decompiles clean on a second attempt. A 404 stays immediate: it is an answer, not a flake, and the sweep asks about plenty of ids that are not packages. Assisted-by: Claude:claude-opus-5[1m]:Claude Code
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds
TestTools/, two standalone tools that run the decompiler over real-worldassemblies. They complement the fixture suite from the other side: it decompiles
code we wrote, these decompile what the world ships.
nugetfuzz.csdecompdiff.csSeveral merged fixes came out of nugetfuzz sweeps (#3958, #3959, #3960, #3961),
but the tools only existed in a private checkout, so nobody else could run them
and their setup knowledge lived in one head.
Both are file-based apps:
single
.csfiles run withdotnet run <file>.cs. They are in no solution andnot run by CI. The near-empty
Directory.Build.props/Directory.Packages.propsstop MSBuild's upward search, so the repo-wide warnings-as-errors, lock-file and
central-package-management settings do not reach them (central package management
in particular rejects the inline
#:packageversion).nugetfuzz-all.ps1, the catalog sweep driver, is PowerShell rather than bash soit runs on Windows too, which also drops its curl/jq dependency. Two further
Windows adjustments:
decompdiffstaging falls back to copying when Windowswithholds symlink privileges, and report file names are hash-truncated to stay
inside the 260-character path limit.
TestTools/README.mddocuments usage, the reference-assembly handling and theplatform notes.
Verified on Linux: both tools build in-repo; a one-page/one-package sweep runs the
full download/decompile/ledger cycle;
decompdiff9.1 vs 11.0-preview overICSharpCode.Decompiler.dllreports 75 changed types with non-empty inline diffs.The Windows-specific paths are code-path fixes, not a tested run.