diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-14 13:42:30 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-14 13:42:30 +0000 |
commit | 75808db17caf8b960b351e3408e74142f4c85aac (patch) | |
tree | 7989e9c09a4240248bf4658a22208a0a52d991c4 /t/recipes/checks/maintainer-scripts/ancient-version/scripts-supports-ancient-package-version | |
parent | Initial commit. (diff) | |
download | lintian-upstream.tar.xz lintian-upstream.zip |
Adding upstream version 2.117.0.upstream/2.117.0upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 't/recipes/checks/maintainer-scripts/ancient-version/scripts-supports-ancient-package-version')
5 files changed, 51 insertions, 0 deletions
diff --git a/t/recipes/checks/maintainer-scripts/ancient-version/scripts-supports-ancient-package-version/build-spec/debian/changelog.in b/t/recipes/checks/maintainer-scripts/ancient-version/scripts-supports-ancient-package-version/build-spec/debian/changelog.in new file mode 100644 index 0000000..d25031a --- /dev/null +++ b/t/recipes/checks/maintainer-scripts/ancient-version/scripts-supports-ancient-package-version/build-spec/debian/changelog.in @@ -0,0 +1,20 @@ +[% $source %] ([% $version %]) unstable; urgency=low + + * Version reused, new source package name. + + -- [% $author %] [% $date %] + +[% $source %] (0.5) unstable; urgency=low + + * Lintian Test Suite. + * Test: [% $testname %] + + -- [% $author %] Fri, 06 Feb 2009 22:22:37 -0800 + +[% $source %] (0) unstable; urgency=low + + * Lintian Test Suite. + * Should be ignored. + * Test: [% $testname %] + + -- [% $author %] Fri, 06 Feb 2008 22:22:37 -0800 diff --git a/t/recipes/checks/maintainer-scripts/ancient-version/scripts-supports-ancient-package-version/build-spec/debian/postinst b/t/recipes/checks/maintainer-scripts/ancient-version/scripts-supports-ancient-package-version/build-spec/debian/postinst new file mode 100644 index 0000000..9a9a79c --- /dev/null +++ b/t/recipes/checks/maintainer-scripts/ancient-version/scripts-supports-ancient-package-version/build-spec/debian/postinst @@ -0,0 +1,20 @@ +#!/bin/sh + +set -e + +# Bad +dpkg --compare-versions "$2" lt "0.5" +dpkg --compare-versions "$2" lt 0.5~ +dpkg --compare-versions "$2" lt 0.5-1~ +dpkg --compare-versions "$2" lt '0.5-1~' +dpkg --compare-versions '0.5-1~' gt "$2" +if dpkg --compare-versions '0.5-1~' gt "$2"; then :; fi + +# Good +dpkg --compare-versions "$2" lt "0" +dpkg --compare-versions "$2" lt "0~" +dpkg --compare-versions "$2" lt 0.50.5 +# This is a false-positive for 0.5 +# dpkg --compare-versions "$2" lt 0.5~ + +#DEBHELPER# diff --git a/t/recipes/checks/maintainer-scripts/ancient-version/scripts-supports-ancient-package-version/build-spec/fill-values b/t/recipes/checks/maintainer-scripts/ancient-version/scripts-supports-ancient-package-version/build-spec/fill-values new file mode 100644 index 0000000..6036e51 --- /dev/null +++ b/t/recipes/checks/maintainer-scripts/ancient-version/scripts-supports-ancient-package-version/build-spec/fill-values @@ -0,0 +1,3 @@ +Testname: scripts-supports-ancient-package-version +Skeleton: upload-non-native +Description: Check for maintainer scripts supporting old versions diff --git a/t/recipes/checks/maintainer-scripts/ancient-version/scripts-supports-ancient-package-version/eval/desc b/t/recipes/checks/maintainer-scripts/ancient-version/scripts-supports-ancient-package-version/eval/desc new file mode 100644 index 0000000..d58a9e1 --- /dev/null +++ b/t/recipes/checks/maintainer-scripts/ancient-version/scripts-supports-ancient-package-version/eval/desc @@ -0,0 +1,2 @@ +Testname: scripts-supports-ancient-package-version +Check: maintainer-scripts/ancient-version diff --git a/t/recipes/checks/maintainer-scripts/ancient-version/scripts-supports-ancient-package-version/eval/hints b/t/recipes/checks/maintainer-scripts/ancient-version/scripts-supports-ancient-package-version/eval/hints new file mode 100644 index 0000000..0af90ca --- /dev/null +++ b/t/recipes/checks/maintainer-scripts/ancient-version/scripts-supports-ancient-package-version/eval/hints @@ -0,0 +1,6 @@ +scripts-supports-ancient-package-version (binary): maintainer-script-supports-ancient-package-version 0.5 (2009-02-07 < 2021-08-14) [postinst:9] +scripts-supports-ancient-package-version (binary): maintainer-script-supports-ancient-package-version 0.5 (2009-02-07 < 2021-08-14) [postinst:8] +scripts-supports-ancient-package-version (binary): maintainer-script-supports-ancient-package-version 0.5 (2009-02-07 < 2021-08-14) [postinst:7] +scripts-supports-ancient-package-version (binary): maintainer-script-supports-ancient-package-version 0.5 (2009-02-07 < 2021-08-14) [postinst:6] +scripts-supports-ancient-package-version (binary): maintainer-script-supports-ancient-package-version 0.5 (2009-02-07 < 2021-08-14) [postinst:11] +scripts-supports-ancient-package-version (binary): maintainer-script-supports-ancient-package-version 0.5 (2009-02-07 < 2021-08-14) [postinst:10] |