diff options
author | David Kalnischkies <david@kalnischkies.de> | 2015-10-16 12:54:14 +0200 |
---|---|---|
committer | David Kalnischkies <david@kalnischkies.de> | 2015-11-04 18:04:01 +0100 |
commit | 73fe49f9b4748eddb5a2dad4f0abb51a8f63564c (patch) | |
tree | c1199076283004e3f77a88ec804a7dfd1611abfd /test/integration/test-bug-613420-new-garbage-dependency | |
parent | 002b1bc46b18e9d309d337ddb15a6ccdfb6c9dde (diff) |
suggest 'apt autoremove' to get right of unneeded packages
The bugreport is more conservative in asking for a conditional, but
given that this is a message intended to be read by users to be run by
users we should suggest using a command intended to be used by users.
And while we are at, add sudo to the message – conditional of course.
Closes: 801571
Diffstat (limited to 'test/integration/test-bug-613420-new-garbage-dependency')
-rwxr-xr-x | test/integration/test-bug-613420-new-garbage-dependency | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/test/integration/test-bug-613420-new-garbage-dependency b/test/integration/test-bug-613420-new-garbage-dependency index 8424b10b7..8c6fd1f42 100755 --- a/test/integration/test-bug-613420-new-garbage-dependency +++ b/test/integration/test-bug-613420-new-garbage-dependency @@ -11,19 +11,22 @@ insertpackage 'unstable' 'libreoffice-core' 'all' '1:3.3.1~rc1-2' 'Conflicts: op insertpackage 'unstable' 'libreoffice-officebean' 'all' '1:3.3.1~rc1-2' 'Depends: libreoffice-core' insertpackage 'unstable' 'openoffice.org-officebean' 'all' '1:3.3.0-5' 'Depends: libreoffice-officebean' - setupaptarchive touch rootdir/var/lib/apt/extended_states testsuccess aptmark markauto openoffice.org-officebean testmarkedauto openoffice.org-officebean +AUTOREMOVE='apt autoremove' +if [ -n "$SUDO_USER" ]; then + AUTOREMOVE="sudo $AUTOREMOVE" +fi testfailureequal "Reading package lists... Building dependency tree... Reading state information... The following packages were automatically installed and are no longer required: libreoffice-officebean openoffice.org-officebean -Use 'apt-get autoremove' to remove them. +Use '$AUTOREMOVE' to remove them. The following additional packages will be installed: libreoffice-core libreoffice-officebean openoffice.org-officebean The following packages will be REMOVED: @@ -39,7 +42,7 @@ testequal "Reading package lists... Building dependency tree... Reading state information... 2 packages were automatically installed and are no longer required. -Use 'apt-get autoremove' to remove them. +Use '$AUTOREMOVE' to remove them. The following additional packages will be installed: libreoffice-core libreoffice-officebean openoffice.org-officebean The following packages will be REMOVED: |