diff options
author | Panu Matilainen <pmatilai@redhat.com> | 2008-11-21 17:48:27 +0200 |
---|---|---|
committer | Panu Matilainen <pmatilai@redhat.com> | 2008-11-21 17:59:49 +0200 |
commit | 08c81de2ee753778763810add5221e9162d925cb (patch) | |
tree | 7ca0a325522523fe8d3356809c28c480c075c45c /tests/rpmdb.at | |
parent | db6c332c49885163de3b83e200e0b40dcac05dc3 (diff) | |
download | rpm-08c81de2ee753778763810add5221e9162d925cb.tar.gz rpm-08c81de2ee753778763810add5221e9162d925cb.tar.bz2 rpm-08c81de2ee753778763810add5221e9162d925cb.zip |
Hackery to get rpm install tests to "work" with fakechroot
- fakechroot throws it's own curveballs into the already mixed up thing,
copy things to the test dir and set chroot base to that to avoid
confusion with cwd and such
- klunky and ugly but at least the tests pass now when running non-root
Diffstat (limited to 'tests/rpmdb.at')
-rw-r--r-- | tests/rpmdb.at | 31 |
1 files changed, 18 insertions, 13 deletions
diff --git a/tests/rpmdb.at b/tests/rpmdb.at index d95d017c1..9da741b9e 100644 --- a/tests/rpmdb.at +++ b/tests/rpmdb.at @@ -35,8 +35,7 @@ AT_SETUP([rpm -qa]) AT_CHECK([ RPMDB_CLEAR RPMDB_INIT -run rpm \ - --root="${abs_builddir}"/testing \ +runroot rpm \ -qa ], [0]) @@ -52,9 +51,11 @@ AT_CHECK([ RPMDB_CLEAR RPMDB_INIT -run rpm -i \ - --root="${abs_builddir}"/testing \ - "${abs_srcdir}"/data/RPMS/foo-1.0-1.noarch.rpm +tpkg="foo-1.0-1.noarch.rpm" +cp "${RPMDATA}/RPMS/${tpkg}" "${RPMTEST}" + +runroot rpm -i \ + "${tpkg}" ], [0]) @@ -70,10 +71,12 @@ AT_CHECK([ RPMDB_CLEAR RPMDB_INIT -run rpm -i \ - --root="${abs_builddir}"/testing \ - --nodeps --ignorearch --relocate=/usr="${abs_builddir}"/testing/check \ - "${abs_srcdir}"/data/RPMS/hello-1.0-1.i386.rpm +tpkg="hello-1.0-1.i386.rpm" +cp "${RPMDATA}/RPMS/${tpkg}" "${RPMTEST}" + +runroot rpm -i \ + --noscripts --nodeps --ignorearch --relocate=/usr="${abs_builddir}"/testing/check \ + "${tpkg}" ], [0]) @@ -89,10 +92,12 @@ AT_CHECK([ RPMDB_CLEAR RPMDB_INIT -run rpm -i \ - --root="${abs_builddir}"/testing \ - --nodeps --ignorearch --relocate=/usr="${abs_builddir}"/testing/check \ - "${abs_srcdir}"/data/RPMS/hello-1.0-1.ppc64.rpm +tpkg="hello-1.0-1.ppc64.rpm" +cp "${RPMDATA}/RPMS/${tpkg}" "${RPMTEST}" + +runroot rpm -i \ + --noscripts --nodeps --ignorearch --relocate=/usr="${abs_builddir}"/testing/check \ + "${tpkg}" ], [0], [ignore], |