]> git.saurik.com Git - apt.git/blob - test/integration/test-apt-progress-fd-error-postinst
fix test/integration/test-apt-key-net-update (code copy/DRY violation)
[apt.git] / test / integration / test-apt-progress-fd-error-postinst
1 #!/bin/sh
2 set -e
3
4 TESTDIR=$(readlink -f $(dirname $0))
5 . $TESTDIR/framework
6
7 setupenvironment
8 configarchitecture 'amd64' 'i386'
9
10 mkdir -p DEBIAN/
11 echo "#!/bin/sh\nexit 1" > DEBIAN/postinst
12 chmod 755 DEBIAN/postinst
13
14 buildsimplenativepackage 'postinst-error' 'amd64,i386' '0.8.15' 'stable' '' 'pkg with posinst error' '' '' './DEBIAN'
15
16 setupaptarchive
17
18 exec 3> apt-progress.log
19 testfailure aptget install postinst-error -y -o APT::Status-Fd=3
20 msgtest "Ensure correct error message for postinst error"
21 grep -q "pmerror:postinst-error :80:subprocess installed post-installation script returned error exit status 2" apt-progress.log && msgpass || msgfail
22