poldek: poldek/tests/hello.x86_64 (NEW), poldek/tests/sh/01-create-repo, po...
mis
mis at pld-linux.org
Sun May 25 00:50:12 CEST 2008
Author: mis Date: Sat May 24 22:50:12 2008 GMT
Module: poldek Tag: HEAD
---- Log message:
- more tests
---- Files affected:
poldek/poldek/tests:
hello.x86_64 (NONE -> 1.1) (NEW)
poldek/poldek/tests/sh:
01-create-repo (1.1 -> 1.2) , 07-depsolver (1.9 -> 1.10)
---- Diffs:
================================================================
Index: poldek/poldek/tests/hello.x86_64
<<Binary file>>
================================================================
================================================================
Index: poldek/poldek/tests/sh/07-depsolver
diff -u poldek/poldek/tests/sh/07-depsolver:1.9 poldek/poldek/tests/sh/07-depsolver:1.10
--- poldek/poldek/tests/sh/07-depsolver:1.9 Tue May 13 17:59:29 2008
+++ poldek/poldek/tests/sh/07-depsolver Sun May 25 00:50:07 2008
@@ -267,7 +267,7 @@
POLDEK_INSTALL="$POLDEK_INSTALL -Omultilib=1"
msgn "Preparing repositories..."
- for i in i686 x86-64; do
+ for i in i686 x86_64; do
build_installed a 1-1 -a $i -f "/hello.$i"
build_installed a-devel 1-1 -r "'a = 1'" -a $i # -f "/usr/include/foo.h"
build_installed a-static 1-1 -r "'a = 1'" -a $i -f "/sbin/hello.$i"
@@ -279,13 +279,13 @@
rm $DESTINATION_REPO/a-devel*i686* # remove duplicated uncolored package
msgn "Multilib upgrades"
- try_install a-2-2.x86-64 "a-2-2.x86-64" "a-1-1.x86-64"
+ try_install a-2-2.x86_64 "a-2-2.x86_64" "a-1-1.x86_64"
- try_install a-devel-2-2.x86-64 "a-2-2.x86-64,a-devel-2-2.x86-64" \
- "a-1-1.x86-64,a-devel-1-1.x86-64"
+ try_install a-devel-2-2.x86_64 "a-2-2.x86_64,a-devel-2-2.x86_64" \
+ "a-1-1.x86_64,a-devel-1-1.x86_64"
try_install a-devel-2-2.i686 "a-2-2.i686,a-devel-2-2.i686" \
- "a-1-1.i686,a-devel-1-1.x86-64"
+ "a-1-1.i686,a-devel-1-1.x86_64"
msgn "Testing multilib upgrade-dist"
runpoldek --upgrade-dist
@@ -293,7 +293,7 @@
assertEquals "not all packages were upgraded by upgrade-dist" "$n" "0"
# Multilib upgrade uncolored package (arch flip-flop regardless of arch)
- try_install a-devel-2-2.i686 "a-devel-2-2.i686" "a-devel-2-2.x86-64"
+ try_install a-devel-2-2.i686 "a-devel-2-2.i686" "a-devel-2-2.x86_64"
POLDEK_INSTALL="$ORIG_POLDEK_INSTALL"
}
@@ -304,16 +304,16 @@
POLDEK_INSTALL="$POLDEK_INSTALL -Omultilib=1"
msgn "Preparing repositories..."
- for i in i686 x86-64; do
+ for i in i686 x86_64; do
build_installed FooBar 1-1 -a $i -f "/hello.$i" -f "/README"
done
build FooBar 2-2 -a i686 -f "/hello.i686" -f "/README"
- build2 FooBar 2-2 -a x86-64 -f "/hello.x86-64" -f "/README"
+ build2 FooBar 2-2 -a x86_64 -f "/hello.x86_64" -f "/README"
msgn "Up"
- try_install FooBar "FooBar-2-2.i686,FooBar-2-2.x86-64" "FooBar-1-1.i686,FooBar-1-1.x86-64"
+ try_install FooBar "FooBar-2-2.i686,FooBar-2-2.x86_64" "FooBar-1-1.i686,FooBar-1-1.x86_64"
- #"a-2-2.x86-64" "a-1-1.x86-64"
+ #"a-2-2.x86_64" "a-1-1.x86_64"
POLDEK_INSTALL="$ORIG_POLDEK_INSTALL"
}
@@ -384,7 +384,7 @@
msgn "Preparing repositories..."
build n 1-1 -a "noarch" -s "a"
- for i in i686 x86-64; do
+ for i in i686 x86_64; do
build a 1-1 -a $i -f "/hello.$i"
done
POLDEK_TESTING_WITH_SUGGESTS="all" # choose all suggested packages
@@ -404,15 +404,15 @@
build a 2-2 -a $i -r "'a-misc = 2-2'" -f "/hello.$i"
build a-misc 2-2 -a $i -r "'a = 2-2'" -f "/sbin/hello.$i"
- i=x86-64
+ i=x86_64
build2 a 2-2 -a $i -r "'a-misc = 2-2'" -f "/hello.$i"
build2 a-misc 2-2 -a $i -r "'a = 2-2'" -f "/sbin/hello.$i"
- for i in i686 x86-64; do
+ for i in i686 x86_64; do
build_installed a 1-1 -a $i -f "/hello.$i"
build_installed a-misc 1-1 -a $i -r "'a = 1-1'" -f "/sbin/hello.$i"
done
- try_install a-2-2.x86-64 "a-2-2.x86-64,a-misc-2-2.x86-64" "a-1-1.x86-64,a-misc-1-1.x86-64"
+ try_install a-2-2.x86_64 "a-2-2.x86_64,a-misc-2-2.x86_64" "a-1-1.x86_64,a-misc-1-1.x86_64"
POLDEK_INSTALL="$ORIG_POLDEK_INSTALL"
}
@@ -423,14 +423,63 @@
msgn "Preparing repositories..."
arch=amd64
- build_installed a 1-1 -a $arch -f "/hello.x86-64"
- build_installed a-misc 1-1 -a $arch -r "'a = 1-1'" -f "/bin/hello.x86-64"
+ build_installed a 1-1 -a $arch -f "/hello.x86_64"
+ build_installed a-misc 1-1 -a $arch -r "'a = 1-1'" -f "/bin/hello.x86_64"
- arch=x86-64
- build a 2-2 -a $arch -f "/hello.x86-64"
- build a-misc 2-2 -a $arch -f "/sbin/hello.x86-64"
+ arch=x86_64
+ build a 2-2 -a $arch -f "/hello.x86_64"
+ build a-misc 2-2 -a $arch -f "/sbin/hello.x86_64"
- try_install a-2-2.$arch "a-2-2.x86-64,a-misc-2-2.x86-64" "a-1-1.amd64,a-misc-1-1.amd64"
+ try_install a-2-2.$arch "a-2-2.x86_64,a-misc-2-2.x86_64" "a-1-1.amd64,a-misc-1-1.amd64"
+ POLDEK_INSTALL="$ORIG_POLDEK_INSTALL"
+}
+
+#https://bugs.pld-linux.org/show_bug.cgi?id=143#c7
+testMultilibDifferentArchNoColor() {
+ ORIG_POLDEK_INSTALL="$POLDEK_INSTALL"
+ POLDEK_INSTALL="$POLDEK_INSTALL -Omultilib=1"
+
+ msgn "Preparing repositories..."
+ arch=amd64
+ build_installed a 1-1 -a $arch -f "/hello.x86_64"
+ build_installed a-misc 1-1 -a $arch -r "'a = 1-1'" -f "/bin/hello.x86_64"
+ build_installed a-devel 1-1 -a $arch -r "'a = 1-1'" -f "/bin/a.h"
+
+ arch=x86_64
+ build a 2-2 -a $arch -f "/hello.x86_64"
+ build a-misc 2-2 -a $arch -f "/sbin/hello.x86_64"
+ build a-devel 2-2 -a $arch -r "'a = 2-2'" -f "/bin/aa.h"
+ build a-devel 2-2 -a athlon -r "'a = 2-2'" -f "/bin/aaa.h"
+
+ # arch choice of a-devel dependends on environment (rpm/platform)
+ try_install a-2-2.$arch "a-2-2.x86_64,a-misc-2-2.x86_64,a-devel-2-2" "a-1-1.amd64,a-misc-1-1.amd64,a-devel-1-1.amd64"
+ POLDEK_INSTALL="$ORIG_POLDEK_INSTALL"
+}
+
+testMultilibNoSuccesor() {
+ ORIG_POLDEK_INSTALL="$POLDEK_INSTALL"
+ POLDEK_INSTALL="$POLDEK_INSTALL -Omultilib=1"
+
+ msgn "Preparing repositories..."
+ arch=x86_64
+ build_installed a 1-1 -a $arch -f "/hello.$arch"
+ build_installed a-misc 1-1 -a $arch -r "'a = 1-1'" -f "/bin/hello.$arch"
+ build_installed a-devel 1-1 -a $arch -r "'a = 1-1'" -f "/sbin/hello.$arch"
+
+ build a 2-2 -a $arch -f "/hello.$arch"
+ build a-misc 2-2 -a $arch -f "/sbin/hello.$arch"
+ build a-devel 2-2 -a $arch -r "'a = 2-2'" -f "/bin/hello.i686"
+ build a-devel 2-2 -a i686 -r "'a = 2-2'" -f "/bin/hello.i686"
+
+ if is_verbose_mode; then
+ $POLDEK_INSTALL -uvt a-2-2.$arch
+ echo "THE ERROR ABOVE (a = 1-1 is required by installed) is EXPECTED"
+ fi
+ $POLDEK_INSTALL -uvt a-2-2.$arch | grep -q "error: a = 1-1 is required by installed a-devel-1-1.x86_64"
+ assertEquals "poldek should fail" "$?" "0"
+
+ nerrors=$($POLDEK_INSTALL -uvt a-2-2.$arch | grep "^error: " | wc -l)
+ assertEquals "poldek should fail with 2 error:'s" "$nerrors" "2"
POLDEK_INSTALL="$ORIG_POLDEK_INSTALL"
}
@@ -441,9 +490,9 @@
POLDEK_INSTALL="$POLDEK_INSTALL -Omultilib=1"
msgn "Preparing repositories..."
- build_installed a 1-1 -a x86-64 -f "/hello.x86-64"
+ build_installed a 1-1 -a x86_64 -f "/hello.x86_64"
build a 2-2 -a noarch -f "/hello.sh"
- try_install a-2-2.noarch "a-2-2.noarch" "a-1-1.x86-64"
+ try_install a-2-2.noarch "a-2-2.noarch" "a-1-1.x86_64"
POLDEK_INSTALL="$ORIG_POLDEK_INSTALL"
}
================================================================
---- CVS-web:
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/poldek/poldek/tests/sh/01-create-repo?r1=1.1&r2=1.2&f=u
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/poldek/poldek/tests/sh/07-depsolver?r1=1.9&r2=1.10&f=u
More information about the pld-cvs-commit
mailing list