diff options
author | David Kalnischkies <david@kalnischkies.de> | 2014-11-18 13:41:18 +0100 |
---|---|---|
committer | David Kalnischkies <david@kalnischkies.de> | 2014-11-19 18:50:05 +0100 |
commit | 1d838084dc775c0a4184edb4f3b9138903ac27fb (patch) | |
tree | 0a85e1cf02224ffe4d4fdd120b31f80e64b72a32 /test/integration/test-apt-mark | |
parent | b8ef7ef414600109b931fc8eebb1dfafdfe390cd (diff) |
use dpkg --merge-avail only if needed in apt-mark
Only "recent" versions of dpkg support stdin for merge instead of a
file, so as a quick fix we delay calling it until we really need it
which fixes most of the problem already.
Checking for a specific dpkg version here is deemed too much work, just
like using a temporary file here and depends a too high requirement for
this minor usecase. After all, it didn't work at all before, so we break
nobody here and can fix it if someone complains (with a patch).
Diffstat (limited to 'test/integration/test-apt-mark')
-rwxr-xr-x | test/integration/test-apt-mark | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/test/integration/test-apt-mark b/test/integration/test-apt-mark index 0f62a12b4..5a3ae4b2f 100755 --- a/test/integration/test-apt-mark +++ b/test/integration/test-apt-mark @@ -85,6 +85,15 @@ testequal 'E: No packages found' aptmark unhold testnoholdpkg testmarkonepkgashold 'foo' testmarkonepkgashold 'bar' + +msgtest 'dpkg supports --merge-avail via' 'stdin' +if dpkg --merge-avail - < /dev/null >/dev/null 2>&1; then + msgpass +else + msgskip 'dpkg version too old' + exit 0 +fi + testmarkonepkgashold 'uninstalled' testmarkonepkgashold 'uninstalled-native' |