summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorDavid Kalnischkies <david@kalnischkies.de>2016-07-21 15:54:22 +0200
committerDavid Kalnischkies <david@kalnischkies.de>2016-07-22 16:05:10 +0200
commit84255101ee38693aea2fd456cf0da174434afa01 (patch)
tree31b750bbda22bd39b32d7468fa258d4afee37b3e /test
parente04a6ce61db5e5eaf4f954626c7833f00cdb5992 (diff)
use a configurable location for apport report storage
Hardcoding /var/crash means we can't test it properly and it isn't really our style.
Diffstat (limited to 'test')
-rw-r--r--test/integration/framework2
-rwxr-xr-xtest/integration/test-apt-progress-fd-error4
2 files changed, 5 insertions, 1 deletions
diff --git a/test/integration/framework b/test/integration/framework
index 17de023aa..7a6b044aa 100644
--- a/test/integration/framework
+++ b/test/integration/framework
@@ -298,7 +298,7 @@ setupenvironment() {
mkdir rootdir aptarchive keys
cd rootdir
mkdir -p etc/apt/apt.conf.d etc/apt/sources.list.d etc/apt/trusted.gpg.d etc/apt/preferences.d
- mkdir -p usr/bin var/cache var/lib var/log tmp
+ mkdir -p usr/bin var/cache var/lib var/log var/crash tmp
mkdir -p var/lib/dpkg/info var/lib/dpkg/updates var/lib/dpkg/triggers
mkdir -p usr/lib/apt/solvers usr/lib/apt/planners
touch var/lib/dpkg/available
diff --git a/test/integration/test-apt-progress-fd-error b/test/integration/test-apt-progress-fd-error
index 131e50256..e66210304 100755
--- a/test/integration/test-apt-progress-fd-error
+++ b/test/integration/test-apt-progress-fd-error
@@ -12,6 +12,7 @@ touch usr/bin/file-conflict
buildsimplenativepackage 'foo1' 'native' '0.8.15' 'stable' '' 'pkg with file conflicts' '' '' 'usr/'
buildsimplenativepackage 'foo2' 'native' '0.8.15' 'stable' '' 'pkg with file conflicts' '' '' 'usr/'
+insertinstalledpackage 'apport' 'native' '1'
setupaptarchive
@@ -19,3 +20,6 @@ exec 3> apt-progress.log
testfailure aptget install foo1 foo2 -y -o APT::Status-Fd=3
msgtest 'Ensure correct error message'
testsuccess --nomsg grep "aptarchive/pool/foo2_0.8.15_[^.]\+.deb:36.3636:trying to overwrite '/usr/bin/file-conflict', which is also in package foo1 0.8.15" apt-progress.log
+
+testsuccess test -s rootdir/var/crash/foo2.0.crash
+testsuccess grep '^Package: foo2 0.8.15$' rootdir/var/crash/foo2.0.crash