test-apt-progress-fd-error 729 B

1234567891011121314151617181920212223
  1. #!/bin/sh
  2. set -e
  3. TESTDIR=$(readlink -f $(dirname $0))
  4. . $TESTDIR/framework
  5. setupenvironment
  6. configarchitecture 'amd64' 'i386'
  7. mkdir -p usr/bin
  8. touch usr/bin/file-conflict
  9. buildsimplenativepackage 'foo1' 'amd64,i386' '0.8.15' 'stable' '' 'pkg with file conflicts' '' '' 'usr/'
  10. buildsimplenativepackage 'foo2' 'amd64,i386' '0.8.15' 'stable' '' 'pkg with file conflicts' '' '' 'usr/'
  11. setupaptarchive
  12. exec 3> apt-progress.log
  13. testfailure aptget install foo1 foo2 -y -o APT::Status-Fd=3
  14. msgtest "Ensure correct error message"
  15. grep -q "aptarchive/pool/foo2_0.8.15_amd64.deb :40:trying to overwrite '/usr/bin/file-conflict', which is also in package foo1 0.8.15" apt-progress.log && msgpass || (cat apt-progress.log && msgfail)