tests: test if build is reproducible

This commit is contained in:
Natanael Copa 2020-10-29 14:44:52 +00:00
parent 32785f6360
commit c3fb176f24
1 changed files with 15 additions and 0 deletions

View File

@ -38,3 +38,18 @@ teardown() {
options=lib64 $ABUILD
$ABUILD cleanpkg
}
@test "abuild: verify that packages are reproducible built" {
cd testrepo/pkg1
$ABUILD
arch=$($ABUILD -A)
pkgs=$($ABUILD listpkg)
checksums=$( cd "$REPODEST"/testrepo/$arch && md5sum $pkgs)
echo "$checksums"
$ABUILD cleanpkg all
checksums2=$(cd "$REPODEST"/testrepo/$arch && md5sum $pkgs)
echo "$checksums2"
[ "$checksums" = "$checksums2" ]
$ABUILD cleanpkg
}