pub fn inspect(path: impl AsRef<Path>, globs: &[String]) -> Result<Vec<PathBuf>>Expand description
Inspect a built artifact at path for files matching globs — the test-file
patterns that must not ship.
path is either a directory (an already-unpacked artifact) or a packed
archive this rule understands — a Python wheel (.whl, a zip) or a gzipped tar
(.tgz / .tar.gz, e.g. an npm pack tarball or Python sdist; a Cargo
.crate too) — which is unpacked into a scratch directory first. Either way
the unpacked tree is handed to scan. Offenders come back as paths
relative to the artifact root (e.g. package/dist/widget.test.js), so they
read the same whether the artifact was a directory or an archive. Errors if the
artifact can’t be read, or isn’t a directory or a recognized archive.