diff options
author | David Kalnischkies <kalnischkies@gmail.com> | 2011-03-23 01:50:32 +0100 |
---|---|---|
committer | David Kalnischkies <kalnischkies@gmail.com> | 2011-03-23 01:50:32 +0100 |
commit | dfc2b1be9e4e4b500b87df16c21ba85f59d8a587 (patch) | |
tree | 6a5739e823dab13a7b21cfa5115ef32521059b52 /test/integration/framework | |
parent | dde0c674e423e5f06d1e319e3a096054607a5f72 (diff) |
add a method to insert packages into dpkg's status file
Diffstat (limited to 'test/integration/framework')
-rw-r--r-- | test/integration/framework | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/test/integration/framework b/test/integration/framework index 4b1b98c4e..013a71ec0 100644 --- a/test/integration/framework +++ b/test/integration/framework @@ -422,6 +422,29 @@ Filename: pool/main/${NAME}/${NAME}_${VERSION}_${ARCH}.deb" >> $FILE done } +insertinstalledpackage() { + local NAME="$1" + local ARCH="$2" + local VERSION="$3" + local DEPENDENCIES="$4" + local FILE="rootdir/var/lib/dpkg/status" + echo "Package: $NAME +Status: install ok installed +Priority: optional +Section: other +Installed-Size: 42 +Maintainer: Joe Sixpack <joe@example.org> +Architecture: $ARCH +Version: $VERSION" >> $FILE + test -z "$DEPENDENCIES" || echo "$DEPENDENCIES" >> $FILE + echo "Description: an autogenerated dummy ${NAME}=${VERSION}/${RELEASE} + If you find such a package installed on your system, + YOU did something horribly wrong! They are autogenerated + und used only by testcases for APT and surf no other proposeā¦ +" >> $FILE +} + + buildaptarchivefromincoming() { msginfo "Build APT archive for ${CCMD}$(basename $0)${CINFO} based on incoming packagesā¦" cd aptarchive |