2
0
mirror of https://github.com/xcat2/xcat-dep.git synced 2026-09-12 12:36:23 +00:00
Daniel Hilst ee6524ade5 fix(xcat-dep): address PR #62 review -- finalize/genesis/skip correctness + tests
Review feedback (viniciusferrao):

1. --finalize-xcat-dep no longer succeeds with no genesis rpms and no longer treats
   a shared filename as up to date when the content differs.
   - finalize_xcat_dep now REQUIRES each arch's own genesis rpm for every repo pair
     it processes (a pair with none is a hard FATAL, not a silent exit-0 no-op).
   - cross_copy_genesis compares RPM identity by SIGMD5 (header+payload digest,
     independent of the GPG signature), so a stale rpm that merely shares a basename
     is refreshed instead of being mistaken for up to date.

2. Remove the genesis workaround. xcat-core #7696 is merged, so buildrpms.pl now
   exits 0 iff it produced the genesis rpm; the zero-tolerance check no longer
   ignores a genesis failure when a matching (possibly stale) rpm already exists --
   any failed build step, genesis included, fails the run.

3. Skip modes work. required_pkgs() drops the packages whose builder was skipped, and
   both the version-pin check and assert_required_deps use it, so a clean
   --skip-genesis / --skip-xcat-dep / --skip-perl run no longer fails validating
   packages it deliberately did not build.

4. Tests. The reusable, side-effect-free helpers are factored into MockBuildUtils.pm
   (cross_copy_genesis and finalize_xcat_dep take injected sign/reindex callbacks so
   they carry no gpg/createrepo state) and t/mockbuild-all.t adds focused fixture
   tests for all of the above: skip-mode selection, version-pin globs, SIGMD5-based
   RPM-identity comparison + cross_copy refresh/idempotency, and the finalize
   require-inputs guard. Run with `prove t/`.

Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
2026-07-28 16:57:35 -03:00
2013-05-29 14:58:44 +00:00
2008-10-13 15:50:23 +00:00
2011-11-08 18:33:23 +00:00
2009-07-08 18:55:52 +00:00
2020-01-06 16:34:55 -05:00
2018-11-29 05:44:55 -05:00
2020-01-06 16:34:55 -05:00
2018-11-29 05:44:55 -05:00
2008-04-10 19:42:20 +00:00
2011-09-21 19:13:13 +00:00
2018-11-29 05:44:55 -05:00
2018-11-29 05:44:55 -05:00
2018-11-29 05:44:55 -05:00
2022-09-26 16:20:45 +02:00
2018-11-29 05:44:55 -05:00
2018-11-29 05:44:55 -05:00
2009-04-24 20:17:23 +00:00
2016-12-12 13:44:39 -05:00
2026-06-20 17:28:16 -03:00
2018-11-08 00:40:02 -05:00
S
Description
No description provided
223 MiB
Languages
C 89%
Perl 6.7%
Assembly 1.4%
JavaScript 0.8%
Makefile 0.6%
Other 1.4%