From e2bba11c9a1858c98954e7c5299d20a6c0966cc7 Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Wed, 29 Jun 2011 23:26:38 +0200 Subject: - ensure that only the first specific stanza for a package is used - save all stanzas which had no effect in Unmatched --- test/integration/test-pin-non-existent-package | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) (limited to 'test') diff --git a/test/integration/test-pin-non-existent-package b/test/integration/test-pin-non-existent-package index 1031272e2..bd6ccc476 100755 --- a/test/integration/test-pin-non-existent-package +++ b/test/integration/test-pin-non-existent-package @@ -12,7 +12,13 @@ setupaptarchive testcandidate() { msgtest "Test that the Candidate for $1 is" $2 - test "$(aptcache policy $1 | grep '^ Candidate:')" = " Candidate: $2" && msgpass || msgfail + if [ "$(aptcache policy $1 | grep '^ Candidate:')" = " Candidate: $2" ]; then + msgpass + else + echo + aptcache policy $1 + msgfail + fi } testcandidate apt '0.8.15' @@ -36,6 +42,13 @@ Package: doesntexist Pin: release a=unstable Pin-Priority: 1000' >> rootdir/etc/apt/preferences +testcandidate apt '(none)' + +echo ' +Package: apt +Pin: release a=unstable +Pin-Priority: 1000' >> rootdir/etc/apt/preferences + testcandidate apt '(none)' testequal 'N: Unable to locate package doesntexist' aptcache policy doesntexist -q=0 -- cgit v1.2.3