diff options
author | Ralf Corsépius <corsepiu@fedoraproject.org> | 2007-08-30 15:33:15 +0200 |
---|---|---|
committer | Ralf Corsépius <corsepiu@fedoraproject.org> | 2007-08-30 15:33:15 +0200 |
commit | 333fc3b70efdabd2d6928375ec0ce67ef29797fa (patch) | |
tree | 74be399f36fedf5190db6968bd8b46f12697121c /tests/rpmdb.at | |
parent | 1e27f6ec10605daf5fae46a159959706a3827ec4 (diff) | |
download | rpm-333fc3b70efdabd2d6928375ec0ce67ef29797fa.tar.gz rpm-333fc3b70efdabd2d6928375ec0ce67ef29797fa.tar.bz2 rpm-333fc3b70efdabd2d6928375ec0ce67ef29797fa.zip |
Massive hacking on tests.
Diffstat (limited to 'tests/rpmdb.at')
-rw-r--r-- | tests/rpmdb.at | 60 |
1 files changed, 22 insertions, 38 deletions
diff --git a/tests/rpmdb.at b/tests/rpmdb.at index e0dea0b94..d75ca61d3 100644 --- a/tests/rpmdb.at +++ b/tests/rpmdb.at @@ -21,7 +21,8 @@ # Attempt to initialize a rpmdb AT_SETUP([rpm --initdb]) AT_CHECK([ -RPM_INIT_DB +RPMDB_CLEAR +RPMDB_INIT ], [0], [ignore], @@ -32,43 +33,32 @@ AT_CLEANUP # Run rpm -qa on an empty rpmdb AT_SETUP([rpm -qa]) AT_CHECK([ -RPM_INIT_DB +RPMDB_CLEAR +RPMDB_INIT rpm \ - --rcfile=${RPMRC} \ + --rcfile="${RPMRC}" \ --root="${abs_builddir}"/testing \ -qa ], -[0], -[ignore], -[ignore]) +[0]) AT_CLEANUP # ------------------------------ -# 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([ -RPM_INIT_DB -], -[0],[ignore],[ignore]) +# install a noarch package into a local rpmdb without --relocate and --nodeps +# * Should always succeed +AT_SETUP([rpm -i *.noarch.rpm]) AT_CHECK([ +RPMDB_CLEAR +RPMDB_INIT + rpm -i \ - --rcfile=${RPMRC} \ + --rcfile="${RPMRC}" \ --root="${abs_builddir}"/testing \ - --ignorearch \ - "${abs_srcdir}"/data/RPMS/hello-1.0-1.i386.rpm + "${abs_srcdir}"/data/RPMS/foo-1.0-1.noarch.rpm ], -[1], -[ignore], -[error: Failed dependencies: - /bin/sh is needed by hello-1.0-1.i386 - libc.so.6 is needed by hello-1.0-1.i386 - libc.so.6(GLIBC_2.0) is needed by hello-1.0-1.i386 - rtld(GNU_HASH) is needed by hello-1.0-1.i386 -]) +[0]) AT_CLEANUP @@ -79,20 +69,16 @@ AT_CLEANUP # * Use --ignorearch because we don't know the arch AT_SETUP([rpm -i --relocate=.. *.i386.rpm]) AT_CHECK([ -RPM_INIT_DB -], -[0],[ignore],[ignore]) +RPMDB_CLEAR +RPMDB_INIT -AT_CHECK([ rpm -i \ - --rcfile=${RPMRC} \ + --rcfile="${RPMRC}" \ --root="${abs_builddir}"/testing \ --nodeps --ignorearch --relocate=/usr="${abs_builddir}"/testing/check \ "${abs_srcdir}"/data/RPMS/hello-1.0-1.i386.rpm ], -[0], -[ignore], -[ignore]) +[0]) AT_CLEANUP @@ -103,13 +89,11 @@ AT_CLEANUP # * Use --ignorearch because we don't know the arch AT_SETUP([rpm -i --relocate=.. *.ppc64.rpm]) AT_CHECK([ -RPM_INIT_DB -], -[0],[ignore],[ignore]) +RPMDB_CLEAR +RPMDB_INIT -AT_CHECK([ rpm -i \ - --rcfile=${RPMRC} \ + --rcfile="${RPMRC}" \ --root="${abs_builddir}"/testing \ --nodeps --ignorearch --relocate=/usr="${abs_builddir}"/testing/check \ "${abs_srcdir}"/data/RPMS/hello-1.0-1.ppc64.rpm |