Commit Graph

9 Commits

Author SHA1 Message Date
c913d96de3 fix(ci): update integration tests for NameNormalizer, fix lint and Windows CI
- Update apk/pacman/snap/flatpak integration tests to assert
  NameNormalize=true (all managers now implement NameNormalizer)
- Update flatpak integration test to assert VersionQuery=true
- Remove unused aur functions: rpcInfoMulti, getAURBuildDir
- Wire AUR.Clean to call clean() for consistency
- Fix Windows CI: add shell:bash to avoid PowerShell arg splitting
  on -coverprofile=coverage-windows.out
2026-03-06 04:13:39 +00:00
4e90abc6a3 fix: update integration tests for Install/Remove multi-return signature 2026-03-01 00:47:23 +00:00
aa34f1d896 fix(test): relax assertions for cross-distro compatibility
- apk: Search_NoResults may return error instead of empty
- apt: Info may not populate Description; ListRepos URL may be empty
- pacman: Groups may not exist in minimal containers
- dnf: FileList_NotInstalled doesn't guarantee ErrNotInstalled sentinel;
  GroupInfo_NotFound may return empty instead of error;
  Holder tests nested under Hold (skip all if versionlock unavailable)
- flatpak: Info/Version may not work on all app IDs after install
2026-02-26 03:10:55 +00:00
387e951b86 fix: use snack.Manager interface type for type assertions, drop coverpkg 2026-02-26 02:53:39 +00:00
b12f956e45 test: exhaustive integration tests with codecov
- Root package unit tests: Targets, TargetNames, ApplyOptions, error sentinels
- Every provider integration test now covers:
  - All Manager interface methods (positive + negative cases)
  - GetCapabilities verification (assert expected interfaces)
  - VersionQuerier: LatestVersion, ListUpgrades, UpgradeAvailable, VersionCmp
  - Holder: Hold, ListHeld, Unhold (apt, dnf)
  - Cleaner: Autoremove, Clean
  - FileOwner: FileList, Owner (+ not-found cases)
  - RepoManager: ListRepos (apt, dnf, flatpak)
  - KeyManager: ListKeys (apt, dnf)
  - Grouper: GroupList, GroupInfo (pacman, dnf)
  - NameNormalizer: NormalizeName, ParseArch table tests (apt, dpkg, dnf, rpm)
- Containertest matrix: 5 distros (debian, alpine, arch, fedora39, fedora-latest)
- CI: coverage profiles uploaded per-job, merged in codecov job
- Added .gitignore for coverage files
2026-02-26 02:50:48 +00:00
99dfc80003 fix(ci): pin fedora:39 for dnf4, fix test paths for debian/alpine
- Fedora 40+ ships dnf5 (not 41 as assumed) — pin to 39
- Debian container: /usr/bin/bash doesn't exist, use /usr/bin/dpkg
- Alpine: use busybox for LatestVersion test (always available)
2026-02-26 01:55:24 +00:00
0932da4d02 fix(ci): fix integration test failures across distros
- apk: Info test uses busybox (pre-installed) instead of curl (not installed)
- apk: LatestVersion test uses tree (installed during test)
- dpkg: Owner test uses /usr/bin/bash (not /bin/bash symlink)
- flatpak: List test checks both Name and Application ID fields
- dnf: pin Fedora to 41 (dnf4); dnf5 has incompatible output format
2026-02-26 01:52:46 +00:00
fa7bd7a79b fix: use snack.Manager interface type for capability assertions in integration tests
Type assertions require an interface type, not a concrete struct pointer.
Changed all integration tests from 'mgr := pkg.New()' to
'var mgr snack.Manager = pkg.New()' so capability checks like
mgr.(snack.VersionQuerier) compile correctly.
2026-02-26 01:47:25 +00:00
b443269594 feat: add integration tests and GitHub Actions CI
Add integration test files for all providers (apt, dpkg, pacman, apk,
dnf, rpm, flatpak, snap, pkg, detect) behind the 'integration' build
tag. Tests exercise real package operations: update, search, info,
install, verify, list, remove, and capability interfaces.

Add GitHub Actions workflow running unit tests on ubuntu-latest and
integration tests on Debian, Ubuntu, Fedora, Alpine, Arch Linux, and
Ubuntu+Flatpak containers/runners.
2026-02-26 01:42:19 +00:00