diff options
| author | aur-build <aur-build@localhost> | 2026-11-20 20:14:27 +0000 |
|---|---|---|
| committer | aur-build <aur-build@localhost> | 2026-11-20 20:14:27 +0000 |
| commit | 68ec6971b872d8be561e8c2c2748c6c143bfef7d (patch) | |
| tree | 6d8489dbf6d05106b67770b529dc5eb3e849805e /testcorpus/dep-client/manifest.json | |
| parent | e6c3a02229994a9e007d8e6618add778e1ec021c (diff) | |
| download | aur-build-68ec6971b872d8be561e8c2c2748c6c143bfef7d.tar.gz aur-build-68ec6971b872d8be561e8c2c2748c6c143bfef7d.zip | |
pkgver: move the pure version and dependency tests into the module
Ten tests in tests/versions.rs were unit tests of pkgver wearing an
integration test's clothing: the comparison vectors, the chunk rule, the
epoch rules, the dependency grammar, the constraint checks, the recorded
oracle. None of them touched a database or a fixture. They were written
against the crate's public API because that was the only way to reach
them from outside, and that single fact — that a test had to import a
name to exercise it — is what had been keeping five items public:
vercmp_string, Dep, DepOp, Dep::satisfied_by, split_full_version
All five are private now. `vercmp_string` is called by `vercmp` and by
nothing else; `Dep` and `DepOp` are the internals of `dep_names`, which
*is* used in production; `satisfied_by` and `Dep::name` are used only by
this module's tests, so they are gated rather than merely private, and
`cargo check --release` without the test-support feature compiles clean,
which is the proof that nothing production needs them was left behind.
The oracle test now resolves testcorpus/ through CARGO_MANIFEST_DIR
rather than the harness helper, so it no longer depends on the working
directory. The live pacman differential came with it and stays gated on
AUR_LIVE_VERCMP, recording its absence the same way.
What remains in tests/versions.rs is two tests that genuinely need the
harness: they build a package, publish it, and move its upstream.
pkgver: 14 pub / 5 test-only -> 8 pub / 0 test-only.
Suite: 281 passed, 0 failed.
Diffstat (limited to 'testcorpus/dep-client/manifest.json')
0 files changed, 0 insertions, 0 deletions
