Turbopack: discover snapshot fixtures with custom entries (#101495)
### What?
The Turbopack snapshot suite now finds fixtures by their `input`
directory, not by a hard-coded `input/index.js`. This means
`swc_transforms/mono_transforms`, whose `options.json` sets `"entry":
"input/packages/app/index.js"`, now actually runs, and its committed
output is checked again.
### Why?
`tests/snapshot.rs` only created tests for
`tests/snapshot/*/*/input/index.js`. A fixture with a custom `entry` and
no `input/index.js` was silently skipped. Its snapshot could go stale,
and the transform and resolution behavior it covers could regress
without any test failing. `mono_transforms` was the only remaining
fixture in that state. Its old output used the outdated chunk naming.
### How?
- The fixture glob now matches `tests/snapshot/*/*/input`, still
excluding `node_modules`. The test resolves the fixture root as that
directory's parent.
- The entry is still read from `options.json` and defaults to
`input/index.js`, so every fixture keeps its configured entry.
- The generated test names change (`…__input__index_js` → `…__input`).
No fixture was dropped: the only new test is `mono_transforms`.
- Regenerated the `mono_transforms` output. Its JSX in
`packages/component` is transformed, the third-party JSX under
`input/node_modules` is left as is, and no issues are reported. No other
fixture output changed.
### Verification
- `cargo test -p turbopack-tests --test snapshot -- --list`: 24 → 25
fixture tests.
- Appending a junk line to a committed `mono_transforms` output makes
its test fail.
<!-- NEXT_JS_LLM -->
<!-- fleet e14bfac9-cbc0-414d-80d8-bc110b260b6d -->
Co-authored-by: vercel-fleet-prod[bot] <318278635+vercel-fleet-prod[bot]@users.noreply.github.com>
Co-authored-by: Tobias Koppers <1365881+sokra@users.noreply.github.com>