summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRalf Corsépius <corsepiu@fedoraproject.org>2007-08-21 11:09:45 +0200
committerRalf Corsépius <corsepiu@fedoraproject.org>2007-08-21 11:09:45 +0200
commit45e7dca5874e42b6ef2679631a56b3f97ce98cc8 (patch)
tree44508ecd33cb31a7c351836861b2cfb97a4220f2
parent6922fc8882f8934320b625b52387de96d16d5320 (diff)
downloadrpm-45e7dca5874e42b6ef2679631a56b3f97ce98cc8.tar.gz
rpm-45e7dca5874e42b6ef2679631a56b3f97ce98cc8.tar.bz2
rpm-45e7dca5874e42b6ef2679631a56b3f97ce98cc8.zip
More checks.
-rw-r--r--tests/rpmdb.at56
1 files changed, 52 insertions, 4 deletions
diff --git a/tests/rpmdb.at b/tests/rpmdb.at
index a574f6a09..8ca9b2988 100644
--- a/tests/rpmdb.at
+++ b/tests/rpmdb.at
@@ -51,9 +51,9 @@ rpm \
AT_CLEANUP
-
-# install a package into a local rpmdb
-# * Shall only work with relocation
+# install a package into a local rpmdb without --relocate and --nodeps
+# * Must fail due to missing deps
+# * Use --ignorearch because we don't know the arch
AT_SETUP([rpm -i *.i386.rpm])
AT_CHECK([
DBPATH=`rpm --rcfile=${RPMRC} --eval '%_dbpath'`
@@ -70,6 +70,7 @@ AT_CHECK([
rpm -i \
--rcfile=${RPMRC} \
--root="${abs_builddir}"/testing \
+ --ignorearch \
"${abs_srcdir}"/data/RPMS/hello-1.0-1.i386.rpm
],
[1],
@@ -81,11 +82,29 @@ rpm -i \
rtld(GNU_HASH) is needed by hello-1.0-1.i386
])
+AT_CLEANUP
+
+
+# install a package into a local rpmdb
+# * Shall only work with relocation
+# * Use --ignorearch because we don't know the arch
+AT_SETUP([rpm -i --relocate=.. *.i386.rpm])
+AT_CHECK([
+DBPATH=`rpm --rcfile=${RPMRC} --eval '%_dbpath'`
+rm -rf "${abs_builddir}"/testing"${DBPATH}"/*
+
+rpm \
+ --rcfile=${RPMRC} \
+ --root="${abs_builddir}"/testing \
+ --initdb
+],
+[0],[ignore],[ignore])
+
AT_CHECK([
rpm -i \
--rcfile=${RPMRC} \
--root="${abs_builddir}"/testing \
- --nodeps --relocate=/usr="${abs_builddir}"/testing \
+ --nodeps --ignorearch --relocate=/usr="${abs_builddir}"/testing \
"${abs_srcdir}"/data/RPMS/hello-1.0-1.i386.rpm
],
[0],
@@ -93,3 +112,32 @@ rpm -i \
[ignore])
AT_CLEANUP
+
+
+# install a package into a local rpmdb
+# * Shall only work with relocation
+# * Use --ignorearch because we don't know the arch
+AT_SETUP([rpm -i --relocate=.. *.ppc64.rpm])
+AT_CHECK([
+DBPATH=`rpm --rcfile=${RPMRC} --eval '%_dbpath'`
+rm -rf "${abs_builddir}"/testing"${DBPATH}"/*
+
+rpm \
+ --rcfile=${RPMRC} \
+ --root="${abs_builddir}"/testing \
+ --initdb
+],
+[0],[ignore],[ignore])
+
+AT_CHECK([
+rpm -i \
+ --rcfile=${RPMRC} \
+ --root="${abs_builddir}"/testing \
+ --nodeps --ignorearch --relocate=/usr="${abs_builddir}"/testing \
+ "${abs_srcdir}"/data/RPMS/hello-1.0-1.ppc64.rpm
+],
+[0],
+[ignore],
+[ignore])
+
+AT_CLEANUP