]> git.saurik.com Git - apt.git/blobdiff - test/integration/test-bug-720597-build-dep-purge
support APT::Get::Build-Dep-Automatic again in build-dep
[apt.git] / test / integration / test-bug-720597-build-dep-purge
index 6fa261fbdb78c5d4def9b2c537939dc57d3c7a88..c62d546873344db6533f988fae0628efd17b9d23 100755 (executable)
@@ -1,8 +1,8 @@
 #!/bin/sh
 set -e
 
-TESTDIR=$(readlink -f $(dirname $0))
-. $TESTDIR/framework
+TESTDIR="$(readlink -f "$(dirname "$0")")"
+. "$TESTDIR/framework"
 setupenvironment
 configarchitecture 'amd64'
 
@@ -14,6 +14,7 @@ buildsimplenativepackage 'pkgc' 'amd64' '1' 'stable' 'Build-Depends: pkgb'
 setupaptarchive
 
 testsuccessequal 'Reading package lists...
+Reading package lists...
 Building dependency tree...
 The following packages will be REMOVED:
   pkga
@@ -25,6 +26,7 @@ Inst pkgb (1 stable [amd64])
 Conf pkgb (1 stable [amd64])' aptget build-dep pkgc -s
 
 testsuccessequal 'Reading package lists...
+Reading package lists...
 Building dependency tree...
 The following packages will be REMOVED:
   pkga*
@@ -34,3 +36,27 @@ The following NEW packages will be installed:
 Purg pkga [1]
 Inst pkgb (1 stable [amd64])
 Conf pkgb (1 stable [amd64])' aptget build-dep pkgc -s --purge
+
+testsuccessequal 'Reading package lists...
+Building dependency tree...
+0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.' apt autoremove -s
+testdpkgnotinstalled pkgb
+testsuccess apt build-dep pkgc -y -o Debug::pkgDepCache::AutoInstall=1 -o Debug::pkgDepCache::Marker=1
+testdpkginstalled pkgb
+testsuccessequal 'Reading package lists...
+Building dependency tree...
+Reading state information...
+0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.' apt autoremove -s
+testsuccess apt purge pkgb pkgc -y
+testsuccessequal 'Reading package lists...
+Building dependency tree...
+Reading state information...
+0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.' apt autoremove -s
+testsuccess apt build-dep pkgc -y -o APT::Get::Build-Dep-Automatic=true
+testsuccessequal 'Reading package lists...
+Building dependency tree...
+Reading state information...
+The following packages will be REMOVED:
+  pkgb
+0 upgraded, 0 newly installed, 1 to remove and 0 not upgraded.
+Remv pkgb [1]' apt autoremove -s