The following commit has been merged in the master branch: commit 514f5c1039475e26f420a45ddf46b65f2979bba2 Author: Russ Allbery <r...@debian.org> Date: Mon Dec 29 17:24:21 2008 -0800
Add a test case of a generic dh_make template from 2005 Recover the original checkin of the dh-test test case and turn it into a new test case. This is a helpful check of the various boilerplate detection tags and the things dh_make used to recommend that Lintian now warns about. Document the generic- prefix in t/tests/README. diff --git a/t/tests/6500_generic-dh-make-2005.desc b/t/tests/6500_generic-dh-make-2005.desc new file mode 100644 index 0000000..a3017f4 --- /dev/null +++ b/t/tests/6500_generic-dh-make-2005.desc @@ -0,0 +1,21 @@ +Testname: generic-dh-make-2005 +Type: non-native +Author: Frank Lichtenheld <dj...@debian.org> +Version: 1-1 +Description: Generic dh_make template generated in 2005 +Test-For: + ancient-standards-version + copyright-without-copyright-notice + debian-rules-ignores-make-clean-error + debian-rules-sets-DH_COMPAT + debian-watch-file-is-missing + description-is-dh_make-template + dh_suidregister-is-obsolete + dh_testversion-is-deprecated + extended-description-is-probably-too-short + helper-templates-in-copyright + new-package-should-close-itp-bug + package-uses-deprecated-debhelper-compat-version + readme-debian-contains-debmake-template + section-is-dh_make-template + wrong-bug-number-in-closes diff --git a/t/tests/README b/t/tests/README index 7c9d5ff..4c60f40 100644 --- a/t/tests/README +++ b/t/tests/README @@ -9,6 +9,11 @@ e.g. lintian-... lintian-info-... +Use generic- as a prefix for test cases that don't cover a +specific portion of Lintian but instead test Lintian's behavior +on a useful special case of package (such as a generic dh-make +template). + The .desc file names should start with a number to get a more deterministic order. You do not need to use unique numbers, only enough to make the order deterministic and to your liking! diff --git a/t/tests/generic-dh-make-2005/debian/README b/t/tests/generic-dh-make-2005/debian/README new file mode 100644 index 0000000..6c24660 --- /dev/null +++ b/t/tests/generic-dh-make-2005/debian/README @@ -0,0 +1,9 @@ +This is something close to the results of running dh_make on a basically +empty upstream tarball in 2005. It's a useful test for the various +dh_make template and boilerplate tags, as well as many tags for ways +of doing things dh_make used to promote but are now deprecated or old +debhelper commands that are now deprecated. + +Please don't modify anything about the files in this package; instead, add +new tags as needed when Lintian adds new checks. This test case is +intended to continue to be a test of Lintian's handling of old packages. diff --git a/testset/dh-test/debian/README.Debian b/t/tests/generic-dh-make-2005/debian/debian/README.Debian similarity index 100% copy from testset/dh-test/debian/README.Debian copy to t/tests/generic-dh-make-2005/debian/debian/README.Debian diff --git a/testset/dh-test/debian/changelog b/t/tests/generic-dh-make-2005/debian/debian/changelog similarity index 75% copy from testset/dh-test/debian/changelog copy to t/tests/generic-dh-make-2005/debian/debian/changelog index 5886b75..dd3b04e 100644 --- a/testset/dh-test/debian/changelog +++ b/t/tests/generic-dh-make-2005/debian/debian/changelog @@ -1,4 +1,4 @@ -dh-test (1-1) unstable; urgency=low +generic-dh-make-2005 (1-1) unstable; urgency=low * Initial release Closes: #nnnn (nnnn is the bug number of your ITP) diff --git a/testset/dh-test/debian/control b/t/tests/generic-dh-make-2005/debian/debian/control similarity index 71% copy from testset/dh-test/debian/control copy to t/tests/generic-dh-make-2005/debian/debian/control index d0890b2..3bb61c1 100644 --- a/testset/dh-test/debian/control +++ b/t/tests/generic-dh-make-2005/debian/debian/control @@ -1,12 +1,12 @@ -Source: dh-test +Source: generic-dh-make-2005 Section: unknown Priority: optional Maintainer: Frank Lichtenheld <dj...@debian.org> Build-Depends: debhelper (>= 4.0.0) Standards-Version: 3.6.2 -Package: dh-test +Package: generic-dh-make-2005 Architecture: any -Depends: ${shlibs:Depends} +Depends: ${shlibs:Depends}, ${misc:Depends} Description: <insert up to 60 chars description> <insert long description, indented with spaces> diff --git a/testset/dh-test/debian/copyright b/t/tests/generic-dh-make-2005/debian/debian/copyright similarity index 100% copy from testset/dh-test/debian/copyright copy to t/tests/generic-dh-make-2005/debian/debian/copyright diff --git a/testset/dh-test/debian/rules b/t/tests/generic-dh-make-2005/debian/debian/rules similarity index 96% copy from testset/dh-test/debian/rules copy to t/tests/generic-dh-make-2005/debian/debian/rules index 613cf7c..a9fc713 100755 --- a/testset/dh-test/debian/rules +++ b/t/tests/generic-dh-make-2005/debian/debian/rules @@ -9,8 +9,7 @@ # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 -DH_COMPAT=3 -export DH_COMPAT +export DH_COMPAT=2 CFLAGS = -Wall -g @@ -81,9 +80,7 @@ binary-arch: build install # dh_installinit # dh_installcron # dh_installinfo - dh_installxfonts dh_installman - -dh_gnustep # dh_dhelp dh_suidregister dh_link @@ -91,7 +88,6 @@ binary-arch: build install dh_compress dh_fixperms # dh_perl - -dh_lisp # dh_python # dh_makeshlibs dh_installdeb diff --git a/t/tests/generic-dh-make-2005/pre_build b/t/tests/generic-dh-make-2005/pre_build new file mode 100755 index 0000000..eb81665 --- /dev/null +++ b/t/tests/generic-dh-make-2005/pre_build @@ -0,0 +1,7 @@ +#!/bin/sh +# +# dh_make in 2005 didn't generate a compat file for debhelper or a watch +# file, so remove the ones that are copied over from the template. + +rm -f "$1"/debian/compat +rm -f "$1"/debian/watch diff --git a/t/tests/generic-dh-make-2005/tags b/t/tests/generic-dh-make-2005/tags new file mode 100644 index 0000000..05ce5dd --- /dev/null +++ b/t/tests/generic-dh-make-2005/tags @@ -0,0 +1,15 @@ +E: generic-dh-make-2005: description-is-dh_make-template +E: generic-dh-make-2005: helper-templates-in-copyright +E: generic-dh-make-2005: section-is-dh_make-template +I: generic-dh-make-2005 source: debian-watch-file-is-missing +I: generic-dh-make-2005: extended-description-is-probably-too-short +W: generic-dh-make-2005 source: ancient-standards-version 3.6.2 (current is 3.8.0) +W: generic-dh-make-2005 source: debian-rules-ignores-make-clean-error line 47 +W: generic-dh-make-2005 source: debian-rules-sets-DH_COMPAT line 12 +W: generic-dh-make-2005 source: dh_suidregister-is-obsolete +W: generic-dh-make-2005 source: dh_testversion-is-deprecated +W: generic-dh-make-2005 source: package-uses-deprecated-debhelper-compat-version 2 +W: generic-dh-make-2005: copyright-without-copyright-notice +W: generic-dh-make-2005: new-package-should-close-itp-bug +W: generic-dh-make-2005: readme-debian-contains-debmake-template +W: generic-dh-make-2005: wrong-bug-number-in-closes l3:#nnnn diff --git a/t/tests/generic-dh-make-2005/upstream/README b/t/tests/generic-dh-make-2005/upstream/README new file mode 100644 index 0000000..6c24660 --- /dev/null +++ b/t/tests/generic-dh-make-2005/upstream/README @@ -0,0 +1,9 @@ +This is something close to the results of running dh_make on a basically +empty upstream tarball in 2005. It's a useful test for the various +dh_make template and boilerplate tags, as well as many tags for ways +of doing things dh_make used to promote but are now deprecated or old +debhelper commands that are now deprecated. + +Please don't modify anything about the files in this package; instead, add +new tags as needed when Lintian adds new checks. This test case is +intended to continue to be a test of Lintian's handling of old packages. -- Debian package checker -- To UNSUBSCRIBE, email to debian-lint-maint-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org