summaryrefslogtreecommitdiffstats
path: root/t/recipes/checks/menu-format
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--t/recipes/checks/menu-format/desktop-entry-unknown-type/build-spec/debian/install1
-rw-r--r--t/recipes/checks/menu-format/desktop-entry-unknown-type/build-spec/fill-values3
-rw-r--r--t/recipes/checks/menu-format/desktop-entry-unknown-type/build-spec/orig/unknown-type.desktop4
-rw-r--r--t/recipes/checks/menu-format/desktop-entry-unknown-type/eval/desc2
-rw-r--r--t/recipes/checks/menu-format/desktop-entry-unknown-type/eval/hints1
-rw-r--r--t/recipes/checks/menu-format/item-has-needs-dwww/build-spec/debian/install1
-rw-r--r--t/recipes/checks/menu-format/item-has-needs-dwww/build-spec/debian/postinst11
-rw-r--r--t/recipes/checks/menu-format/item-has-needs-dwww/build-spec/debian/postrm7
-rw-r--r--t/recipes/checks/menu-format/item-has-needs-dwww/build-spec/fill-values3
-rw-r--r--t/recipes/checks/menu-format/item-has-needs-dwww/build-spec/orig/test-menu5
-rw-r--r--t/recipes/checks/menu-format/item-has-needs-dwww/eval/desc2
-rw-r--r--t/recipes/checks/menu-format/item-has-needs-dwww/eval/hints2
-rw-r--r--t/recipes/checks/menu-format/legacy-binary/build-spec/debian/NEWS.Debian12
-rw-r--r--t/recipes/checks/menu-format/legacy-binary/build-spec/debian/README.Debian5
-rw-r--r--t/recipes/checks/menu-format/legacy-binary/build-spec/debian/changelog.in47
-rw-r--r--t/recipes/checks/menu-format/legacy-binary/build-spec/debian/conffiles1
-rw-r--r--t/recipes/checks/menu-format/legacy-binary/build-spec/debian/control42
-rw-r--r--t/recipes/checks/menu-format/legacy-binary/build-spec/debian/copyright15
-rw-r--r--t/recipes/checks/menu-format/legacy-binary/build-spec/debian/doc-base41
-rw-r--r--t/recipes/checks/menu-format/legacy-binary/build-spec/debian/goodbye.desktop13
-rw-r--r--t/recipes/checks/menu-format/legacy-binary/build-spec/debian/hello.desktop14
-rw-r--r--t/recipes/checks/menu-format/legacy-binary/build-spec/debian/menu26
-rw-r--r--t/recipes/checks/menu-format/legacy-binary/build-spec/debian/menu-method22
-rw-r--r--t/recipes/checks/menu-format/legacy-binary/build-spec/debian/postinst6
-rwxr-xr-xt/recipes/checks/menu-format/legacy-binary/build-spec/debian/rules92
-rw-r--r--t/recipes/checks/menu-format/legacy-binary/build-spec/debian/templates16
-rw-r--r--t/recipes/checks/menu-format/legacy-binary/build-spec/fill-values5
-rw-r--r--t/recipes/checks/menu-format/legacy-binary/build-spec/orig/INSTALL176
-rw-r--r--t/recipes/checks/menu-format/legacy-binary/build-spec/orig/Makefile12
-rw-r--r--t/recipes/checks/menu-format/legacy-binary/build-spec/orig/hello.c8
-rw-r--r--t/recipes/checks/menu-format/legacy-binary/eval/desc2
-rw-r--r--t/recipes/checks/menu-format/legacy-binary/eval/hints63
-rw-r--r--t/recipes/checks/menu-format/legacy-binary/eval/post-test3
-rw-r--r--t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/debian/install8
-rwxr-xr-xt/recipes/checks/menu-format/menu-format-desktop-general/build-spec/debian/rules10
-rw-r--r--t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/fill-values3
-rw-r--r--t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/crlf.desktop7
-rw-r--r--t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/directory.desktop5
-rw-r--r--t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/environments.desktop9
-rw-r--r--t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/general.desktop13
-rw-r--r--t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/link.desktop6
-rw-r--r--t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/missing.desktop5
-rw-r--r--t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/reserved-bad.desktop8
-rw-r--r--t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/reserved.desktop9
-rw-r--r--t/recipes/checks/menu-format/menu-format-desktop-general/eval/desc3
-rw-r--r--t/recipes/checks/menu-format/menu-format-desktop-general/eval/hints16
-rw-r--r--t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/debian/control.in16
-rw-r--r--t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/debian/menu-mime.install2
-rw-r--r--t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/debian/menu-mime.manpages1
-rw-r--r--t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/fill-values4
-rw-r--r--t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/orig/Makefile6
-rw-r--r--t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/orig/bar.desktop10
-rw-r--r--t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/orig/foo.desktop9
-rw-r--r--t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/orig/pargs22
-rw-r--r--t/recipes/checks/menu-format/menu-format-desktop-mimetype/eval/desc3
-rw-r--r--t/recipes/checks/menu-format/menu-format-desktop-mimetype/eval/hints1
-rw-r--r--t/recipes/checks/menu-format/menu-format-general/build-spec/debian/control.in51
-rw-r--r--t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-broken.install1
-rw-r--r--t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-broken.manpages1
-rw-r--r--t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-broken.menu12
-rw-r--r--t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-cmd.install2
-rw-r--r--t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-cmd.menu4
-rw-r--r--t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-none.install1
-rw-r--r--t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-none.manpages1
-rw-r--r--t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-none.menu16
-rw-r--r--t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-section.install2
-rw-r--r--t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-section.manpages1
-rw-r--r--t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-section.menu15
-rw-r--r--t/recipes/checks/menu-format/menu-format-general/build-spec/fill-values3
-rw-r--r--t/recipes/checks/menu-format/menu-format-general/build-spec/orig/Makefile11
-rw-r--r--t/recipes/checks/menu-format/menu-format-general/build-spec/orig/broken.xpm1
-rw-r--r--t/recipes/checks/menu-format/menu-format-general/build-spec/orig/pargs22
-rw-r--r--t/recipes/checks/menu-format/menu-format-general/build-spec/orig/pargs.desktop8
-rw-r--r--t/recipes/checks/menu-format/menu-format-general/build-spec/orig/pargs.png0
-rw-r--r--t/recipes/checks/menu-format/menu-format-general/build-spec/orig/too-large.xpm10
-rw-r--r--t/recipes/checks/menu-format/menu-format-general/eval/desc2
-rw-r--r--t/recipes/checks/menu-format/menu-format-general/eval/hints30
-rw-r--r--t/recipes/checks/menu-format/unknown-menu-tag/build-spec/debian/install1
-rw-r--r--t/recipes/checks/menu-format/unknown-menu-tag/build-spec/debian/postinst11
-rw-r--r--t/recipes/checks/menu-format/unknown-menu-tag/build-spec/debian/postrm7
-rw-r--r--t/recipes/checks/menu-format/unknown-menu-tag/build-spec/fill-values3
-rw-r--r--t/recipes/checks/menu-format/unknown-menu-tag/build-spec/orig/test-menu6
-rw-r--r--t/recipes/checks/menu-format/unknown-menu-tag/eval/desc2
-rw-r--r--t/recipes/checks/menu-format/unknown-menu-tag/eval/hints2
-rw-r--r--t/recipes/checks/menu-format/whitespace-after-continuation-character/build-spec/debian/install1
-rw-r--r--t/recipes/checks/menu-format/whitespace-after-continuation-character/build-spec/debian/postinst11
-rw-r--r--t/recipes/checks/menu-format/whitespace-after-continuation-character/build-spec/debian/postrm7
-rw-r--r--t/recipes/checks/menu-format/whitespace-after-continuation-character/build-spec/fill-values3
-rw-r--r--t/recipes/checks/menu-format/whitespace-after-continuation-character/build-spec/orig/test-menu5
-rw-r--r--t/recipes/checks/menu-format/whitespace-after-continuation-character/eval/desc2
-rw-r--r--t/recipes/checks/menu-format/whitespace-after-continuation-character/eval/hints3
91 files changed, 1097 insertions, 0 deletions
diff --git a/t/recipes/checks/menu-format/desktop-entry-unknown-type/build-spec/debian/install b/t/recipes/checks/menu-format/desktop-entry-unknown-type/build-spec/debian/install
new file mode 100644
index 0000000..af33e1a
--- /dev/null
+++ b/t/recipes/checks/menu-format/desktop-entry-unknown-type/build-spec/debian/install
@@ -0,0 +1 @@
+unknown-type.desktop usr/share/applications
diff --git a/t/recipes/checks/menu-format/desktop-entry-unknown-type/build-spec/fill-values b/t/recipes/checks/menu-format/desktop-entry-unknown-type/build-spec/fill-values
new file mode 100644
index 0000000..f604a1b
--- /dev/null
+++ b/t/recipes/checks/menu-format/desktop-entry-unknown-type/build-spec/fill-values
@@ -0,0 +1,3 @@
+Skeleton: upload-native
+Testname: desktop-entry-unknown-type
+Description: Test desktop file type field value validity
diff --git a/t/recipes/checks/menu-format/desktop-entry-unknown-type/build-spec/orig/unknown-type.desktop b/t/recipes/checks/menu-format/desktop-entry-unknown-type/build-spec/orig/unknown-type.desktop
new file mode 100644
index 0000000..41dd262
--- /dev/null
+++ b/t/recipes/checks/menu-format/desktop-entry-unknown-type/build-spec/orig/unknown-type.desktop
@@ -0,0 +1,4 @@
+[Desktop Entry]
+Type=foo
+Name=unknown-type
+Comment=Type should be one of Application, Link or Directory
diff --git a/t/recipes/checks/menu-format/desktop-entry-unknown-type/eval/desc b/t/recipes/checks/menu-format/desktop-entry-unknown-type/eval/desc
new file mode 100644
index 0000000..8d7cef4
--- /dev/null
+++ b/t/recipes/checks/menu-format/desktop-entry-unknown-type/eval/desc
@@ -0,0 +1,2 @@
+Testname: desktop-entry-unknown-type
+Check: menu-format
diff --git a/t/recipes/checks/menu-format/desktop-entry-unknown-type/eval/hints b/t/recipes/checks/menu-format/desktop-entry-unknown-type/eval/hints
new file mode 100644
index 0000000..5e785a9
--- /dev/null
+++ b/t/recipes/checks/menu-format/desktop-entry-unknown-type/eval/hints
@@ -0,0 +1 @@
+desktop-entry-unknown-type (binary): desktop-entry-unknown-type foo [usr/share/applications/unknown-type.desktop]
diff --git a/t/recipes/checks/menu-format/item-has-needs-dwww/build-spec/debian/install b/t/recipes/checks/menu-format/item-has-needs-dwww/build-spec/debian/install
new file mode 100644
index 0000000..c2ba969
--- /dev/null
+++ b/t/recipes/checks/menu-format/item-has-needs-dwww/build-spec/debian/install
@@ -0,0 +1 @@
+test-menu usr/share/menu
diff --git a/t/recipes/checks/menu-format/item-has-needs-dwww/build-spec/debian/postinst b/t/recipes/checks/menu-format/item-has-needs-dwww/build-spec/debian/postinst
new file mode 100644
index 0000000..024178d
--- /dev/null
+++ b/t/recipes/checks/menu-format/item-has-needs-dwww/build-spec/debian/postinst
@@ -0,0 +1,11 @@
+#!/bin/sh
+set -e
+
+# Checks that the maintainer script checks for the existence of programs that
+# it calls. This should produce no warnings except a bashism warning about
+# using type, a warning about the deprecated wm-menu-config invocation, and a
+# warning for calling the deprecated install-docs outside of a trigger.
+
+if [ -x /usr/bin/update-menus ] ; then update-menus ; fi
+
+#DEBHELPER#
diff --git a/t/recipes/checks/menu-format/item-has-needs-dwww/build-spec/debian/postrm b/t/recipes/checks/menu-format/item-has-needs-dwww/build-spec/debian/postrm
new file mode 100644
index 0000000..c2274f3
--- /dev/null
+++ b/t/recipes/checks/menu-format/item-has-needs-dwww/build-spec/debian/postrm
@@ -0,0 +1,7 @@
+#!/bin/sh
+set -e
+if type update-menus >/dev/null 2>&1 ; then
+ update-menus
+fi
+
+#DEBHELPER#
diff --git a/t/recipes/checks/menu-format/item-has-needs-dwww/build-spec/fill-values b/t/recipes/checks/menu-format/item-has-needs-dwww/build-spec/fill-values
new file mode 100644
index 0000000..dec694b
--- /dev/null
+++ b/t/recipes/checks/menu-format/item-has-needs-dwww/build-spec/fill-values
@@ -0,0 +1,3 @@
+Testname: item-has-needs-dwww
+Skeleton: upload-native
+Description: Test with a menu file that contains an obsolete entry for needs=dwww
diff --git a/t/recipes/checks/menu-format/item-has-needs-dwww/build-spec/orig/test-menu b/t/recipes/checks/menu-format/item-has-needs-dwww/build-spec/orig/test-menu
new file mode 100644
index 0000000..57d65fb
--- /dev/null
+++ b/t/recipes/checks/menu-format/item-has-needs-dwww/build-spec/orig/test-menu
@@ -0,0 +1,5 @@
+?package(item-has-needs-dwww):\
+ section="Applications/Programming"\
+ needs="dwww"\
+ title="Test menu entry"\
+ command="/usr/bin/test-script"
diff --git a/t/recipes/checks/menu-format/item-has-needs-dwww/eval/desc b/t/recipes/checks/menu-format/item-has-needs-dwww/eval/desc
new file mode 100644
index 0000000..04c3af8
--- /dev/null
+++ b/t/recipes/checks/menu-format/item-has-needs-dwww/eval/desc
@@ -0,0 +1,2 @@
+Testname: item-has-needs-dwww
+Check: menu-format
diff --git a/t/recipes/checks/menu-format/item-has-needs-dwww/eval/hints b/t/recipes/checks/menu-format/item-has-needs-dwww/eval/hints
new file mode 100644
index 0000000..06247e3
--- /dev/null
+++ b/t/recipes/checks/menu-format/item-has-needs-dwww/eval/hints
@@ -0,0 +1,2 @@
+item-has-needs-dwww (binary): menu-item-needs-dwww [usr/share/menu/test-menu:5]
+item-has-needs-dwww (binary): menu-command-not-in-package usr/bin/test-script [usr/share/menu/test-menu:5]
diff --git a/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/NEWS.Debian b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/NEWS.Debian
new file mode 100644
index 0000000..29f561c
--- /dev/null
+++ b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/NEWS.Debian
@@ -0,0 +1,12 @@
+binary (4-1.1) UNRELEASED; urgency=high
+
+ This is a Debian NEWS entry that isn't encoded properly in UTF-8: ü.
+ It also has a usefull speling error.
+
+ -- Russ Allbery <rra@debian.org> Sun, 14 Oct 2007 17:11:36 -0700
+
+binary (1) unstable; urgency=low
+
+ This is another entry but this one isn't syntactically valid.
+
+ -- Russ Allbery 2007-10-14
diff --git a/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/README.Debian b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/README.Debian
new file mode 100644
index 0000000..94bcc0a
--- /dev/null
+++ b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/README.Debian
@@ -0,0 +1,5 @@
+this is a binary package to test lintian's handling of bins.
+Check handling of D-Bus and dbus (neither of which should produce
+warnings).
+
+ -- Russ Allbery <rra@debian.org>, Wed, 6 Feb 2008 18:35:11 -0800
diff --git a/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/changelog.in b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/changelog.in
new file mode 100644
index 0000000..39301d6
--- /dev/null
+++ b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/changelog.in
@@ -0,0 +1,47 @@
+binary ([% $version %]) [% $distribution %]; urgency=low
+
+ * I'm doing an comaintainer-upload, acknowledging a NMU, but with a version
+ number which suggests I'm doing a NMU myself.
+
+ Lintian-maintainers: Please don't update this changelog, otherwise you'll
+ probably break the checks/nmu checks.
+
+ -- Jeroen van Wolffelaar <jeroen@wolffelaar.nl> Sun, 18 Apr 2004 01:49:42 +0200
+
+binary (4-1) unstable; urgency=low
+
+ * Weird version number for the new check for accidents with native
+ packaging.
+ * Date was fixed by BR and this test was put on changelog-file-strange-date
+ due to dpkg bug, see #794674.
+
+ -- Marc 'HE' Brockschmidt <he@debian.org> Thu, 15 Apr 2004 23:33:51 +0200
+
+binary (4) unstable; urgency=low
+
+ * Add big file to /usr/share to trigger the big-usr-share check
+
+ -- Jeroen van Wolffelaar <jeroen@wolffelaar.nl> Fri, 27 Feb 2004 10:15:59 +0100
+
+binary (3) unstable; urgency=unlimited
+
+ * Add some bogus menu entries using su-to-root in a bogus way
+
+ -- Jeroen van Wolffelaar <jeroen@wolffelaar.nl> Thu, 12 Feb 2004 20:11:22 +0100
+
+binary (2) unstable; urgency=low
+
+ * Added an INSTALL document which policy 6.3 suggests not to do
+
+ -- Sean 'Shaleh' Perry <shaleh@debian.org> Tue, 30 Jan 2001 15:23:59 -0800
+
+binary (1) unstable; urgency=low
+
+ * hello.c added
+ * hello-static is same as hello, but compiled statically
+ * added a menu entry which lacks a Section
+ * added a postinst
+ * postinst calls suidregister which is no longer policy compliant
+
+ -- Sean 'Shaleh' Perry <shaleh@debian.org> Wed, 10 Jan 2001 08:55:34 -0800
+
diff --git a/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/conffiles b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/conffiles
new file mode 100644
index 0000000..d1a0843
--- /dev/null
+++ b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/conffiles
@@ -0,0 +1 @@
+/etc/menu-methods/lintian
diff --git a/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/control b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/control
new file mode 100644
index 0000000..c797357
--- /dev/null
+++ b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/control
@@ -0,0 +1,42 @@
+Source: binary
+Section: misc
+Priority: optional
+Maintainer: Lintian Maintainers <lintian-maint@debian.org>
+Uploaders: Co-maintainer one <one@debian.org>, Jeroen van Wolffelaar <jeroen@wolffelaar.nl>, Co-maintainer three <three@debian.org>
+Standards-Version: 3.2.1
+Homepage: http://lintian.debian.org/
+Vcs-Svn: http://svn.wolffelaar.nl/lintian/trunk
+XS-Vcs-Browser: http://svn.wolffelaar.nl/lintian/trunk
+XS-Dm-Upload-Allowed: yes
+
+Package: binary
+Architecture: any
+Pre-Depends: ${shlibs:Depends}, xorg, binary-data (= ${source:Version}), libssl0.9.8
+Homepage: <http://lintian.debian.org/>
+Vcs-Svn: http://svn.wolffelaar.nl/lintian/trunk
+Description: test handling of binary files
+ Regression test for lintian's handling of binary files for debian. This
+ is checked for picky spelling errors.
+ .
+ This package list [ subversion | gconf ] should not be flagged as a spelling
+ mistake. The spelling correction for dont should be correct.
+ .
+ Homepage: http://lintian.debian.org/
+
+Package: binary-data
+Architecture: all
+Depends: binary (= ${source:Version}), libssl-not-openssl,
+ libssl0.9.8 | or-something-else
+Description: test handling of binary relationships
+ Regression test for lintian's checking of package relationships between
+ arch:any and arch:all packages.
+ .
+ This mention of subversion should be flagged as a spelling mistake.
+
+#Package: binary-comment
+#Architecture: space-almonds
+#Depends: *
+#Depends: *
+#Description: test comment support
+# Yes, comments are actually allowed in debian/control, so none of the
+# above should produce errors.
diff --git a/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/copyright b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/copyright
new file mode 100644
index 0000000..1d6806d
--- /dev/null
+++ b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/copyright
@@ -0,0 +1,15 @@
+hello.c is released under public domain. This is distributed in the hope that
+it will be useful, but without any warranty; without even the implied warranty
+of merchantability or fitness for a particular purpose.
+
+A reference to /usr/share/common-licenses/GPL-2 to make it look like this
+package is under the GPL and trigger the OpenSSL warning.
+
+Test for old FSF address:
+
+Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+Boston, MA 02111-1307, USA.
+
+Test for deprecated nätionäl äncoding.
+
+Improper capitalization of linux or debian isn't caught here.
diff --git a/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/doc-base b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/doc-base
new file mode 100644
index 0000000..7e5b38f
--- /dev/null
+++ b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/doc-base
@@ -0,0 +1,41 @@
+Document: binary!docs
+Title: Broken debian binary doc-base control file
+Author: Russ Allbery
+Abstract: This control file exercises various tests of doc-base control
+ files, including several things that aren't tested yet. The third and
+ fourth one has trailing whitespace.
+ .
+ This section has a speling error and bad ® character.
+ .
+ The above separator was fine.
+Section: Non/Existant
+Unknown: Some field
+
+
+
+Format: debiandoc-sgML
+Files: /usr/share/doc/binary/binary.sgml.gz
+Unknown: Some field
+
+Format: ESP
+Index: /usr/share/doc/binary/binary.txt
+
+Index: /usr/share/doc/binary/html/index.html
+ /usr/share/doc/binary/html/ch1.html
+ /usr/share/doc/binary/html/ch4.html
+
+
+Format: HTML
+Index: /usr/share/doc/binary/html/index.html
+Files: /usr/share/doc/binary/html/ch?.h*l
+ /usr/share/doc/binary/hml/*.html
+
+Format: inFO
+Files: /usr/share/info/binary.info.gz
+
+Format: HTML
+Index: /usr/share/doc/binary/html/index.html
+Files: /usr/share/doc/binary/html/ch5.html
+ /usr/share/doc/binary/html/ch6.html
+
+
diff --git a/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/goodbye.desktop b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/goodbye.desktop
new file mode 100644
index 0000000..f6ce8e3
--- /dev/null
+++ b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/goodbye.desktop
@@ -0,0 +1,13 @@
+[Desktop Entry]
+Name:Goodbye
+# Name=Goodbye
+Comment=Say hello!
+SpecialTag=This doesn't exist!
+Exec=goodbye
+icon=hello
+Terminal=true
+Type=Application
+Categories=WeirdStuff;Screensaver;
+Encoding=ISO-10646-1
+[Other Entry]
+Name=Goodbye
diff --git a/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/hello.desktop b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/hello.desktop
new file mode 100644
index 0000000..f795468
--- /dev/null
+++ b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/hello.desktop
@@ -0,0 +1,14 @@
+# some random comment
+
+# [Foo Bar]
+[KDE Desktop Entry]
+Name=Hello
+Name[en_US]=Hello
+Comment=Say hello!
+Exec=kdesu hello
+Icon=hello
+Terminal=true
+Type=Application
+Categories=GNOME;GTK;System;Applet;X-Foo;Settings;
+Encoding=UTF-8
+OnlyShowIn=GNOME;
diff --git a/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/menu b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/menu
new file mode 100644
index 0000000..e8972f4
--- /dev/null
+++ b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/menu
@@ -0,0 +1,26 @@
+?package(binary):needs=text title="Hello World" command="/usr/bin/hello"
+?package(binary):needs=text section="Applications/System" title="Run cfdisk (0)" command="/usr/bin/su-to-root cfdisk"
+?package(binary):needs="text" section="Applications/System/Hardware" title="Run cfdisk (1)" command="sux -p cfdisk"
+?package(binary):needs="x11" section="Window Managers" title="Run xfdisk" command="/usr/sbin/su-to-root -c xfdisk"
+?package(binary):needs="wm" section="Applications/System/Administration" title="Run fdisk-wm" command="su-to-root -c hello"
+?package(binary):section="Apps/Games" title="I'm not root!" command="su-to-root -c imnothere"
+?package(binary):needs="text" section="Apps/System" title="I'm not here!" command="/imnothere"
+?package(binary,other-binary):\
+ needs="text"\
+ section="Applications/Shells"\
+ title="more than one required"\
+ command="other-bin -s omething"
+?package(binary):needs="wmmodule" section="WindowManagers/Modules" title="somemodule" command="ModuleCmd"
+?package(binary):needs="wmmodule" section="FVWM Modules" title="somemodule" command="ModuleCmd"
+?package(binary):needs="text" section="Applications/System/Administration" title="I'm not in /usr/bin!" command="iminusrbin"
+?package(binary):needs="text"\
+ section="Applications/System/Administration"\
+ title="I'm not root!" command="su-to-root -c imnothere"
+?package(binary):needs="text" section="Applications/System/Administration"\
+ title="Run cfdisk (0)" command="cfdisk"
+?package(binary):needs="text" section="Applications/System/Administration" title="Hello World" command="/usr/bin/hello"
+?package(binary):needs="wm" section="FVWM Modules" title="Fake Module" command="hello"
+?package(binary):needs="fvwmmodule" section="Window Maker" title="Fake Module"\
+ command="hello"
+?package(binary):needs="x11" section="Applications/System/Hardware" title="Run xfdisk" command="su-to-root -c 'xfdisk -f'"
+?package(binary):needs="text" section="Applications/System/Administration" title="foo" command="sh /path/to/foo"
diff --git a/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/menu-method b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/menu-method
new file mode 100644
index 0000000..9f07bd7
--- /dev/null
+++ b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/menu-method
@@ -0,0 +1,22 @@
+#!/usr/bin/install-menu
+
+# -*- mode: shell-script; -*-
+#I need menu-1!
+#
+
+!include notmenu.h
+
+compat="menu-2"
+
+outputencoding="UTF-8";
+outputlanguage="C";
+
+x11 = AppEntry("false");
+text = AppEntry("true");
+
+startmenu = "";
+endmenu = "";
+submenutitle = "";
+rootprefix = "/var/lib/lintian/menu";
+userprefix = ".local/share/lintian/menu";
+
diff --git a/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/postinst b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/postinst
new file mode 100644
index 0000000..29e1861
--- /dev/null
+++ b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/postinst
@@ -0,0 +1,6 @@
+#! /bin/bash -e
+
+if [ $1 eq 'configure' ]
+then
+ suidregister hello-static root root 4755
+fi
diff --git a/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/rules b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/rules
new file mode 100755
index 0000000..a962ea9
--- /dev/null
+++ b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/rules
@@ -0,0 +1,92 @@
+#!/usr/bin/make -f
+
+tmp=debian/tmp
+
+# This reference to $(PWD) should not cause an error but the one below
+# should.
+build-arch:
+ make
+ echo $(PWD)
+
+build: build-arch
+
+clean:
+ make -i clean
+ [ ! -f debian/files ] || rm -f debian/files
+ [ ! -f debian/substvars ] || rm -f debian/substvars
+ [ ! -d debian/tmp ] || rm -rf debian/tmp
+ [ ! -d debian/binary ] || rm -rf debian/binary
+ [ ! -d debian/binary-data ] || rm -rf debian/binary-data
+
+binary-arch: build
+ install -d $(tmp)/usr/bin
+ install -d $(tmp)/boot/hello
+ install -m 755 hello $(tmp)/usr/bin
+ touch $(tmp)/usr/bin/iminusrbin
+ chmod 755 $(tmp)/usr/bin/iminusrbin
+ install -m 755 hello-static $(tmp)/usr/bin
+ strip $(tmp)/usr/bin/hello-static
+ install -m 755 hello-static $(tmp)/usr/bin/hello.static
+ strip --remove-section=.comment --remove-section=.note $(tmp)/usr/bin/hello.static
+ ln $(tmp)/usr/bin/hello.static $(tmp)/usr/bin/static-hello
+ install -m 755 hello-static $(tmp)/boot/hello
+ strip --remove-section=.comment --remove-section=.note $(tmp)/boot/hello/hello-static
+ install -d $(tmp)/usr/share/doc/binary
+ install -m 644 INSTALL $(tmp)/usr/share/doc/binary
+ install -d $(tmp)/usr/share/doc/binary/html
+ echo '<html></html>' > $(tmp)/usr/share/doc/binary/html/index.html
+ echo '<html></html>' > $(tmp)/usr/share/doc/binary/html/ch1.html
+ ln -s ../html/./ch1.html $(tmp)/usr/share/doc/binary/html/ch2.html
+ ln -s /usr/share/doc/binary/htm/ch1.html $(tmp)/usr/share/doc/binary/html/ch3.html
+ echo '<html></html>' > $(tmp)/usr/share/doc/binary/html/ch5.html
+ ln $(tmp)/usr/share/doc/binary/html/ch5.html \
+ $(tmp)/usr/share/doc/binary/html/ch6.html
+ install -d $(tmp)/usr/share/menu
+ install -d $(tmp)/usr/lib/menu
+ install -d $(tmp)/usr/share/binary
+ install -m 644 debian/menu $(tmp)/usr/share/menu/binary
+ install -m 644 debian/menu $(tmp)/usr/lib/menu/binary
+ install -d $(tmp)/etc/menu-methods
+ install -m 755 debian/menu-method $(tmp)/etc/menu-methods/lintian
+ install -d $(tmp)/usr/share/doc-base
+ install -m 644 debian/doc-base $(tmp)/usr/share/doc-base/binary
+ touch '$(tmp)/usr/share/doc-base/space '
+ install -m 644 debian/README.Debian $(tmp)/usr/share/doc/binary
+ install -m 644 debian/NEWS.Debian $(tmp)/usr/share/doc/binary
+ gzip -n -9 $(tmp)/usr/share/doc/binary/NEWS.Debian
+ install -m 644 debian/copyright $(tmp)/usr/share/doc/binary
+ install -m 644 debian/changelog $(tmp)/usr/share/doc/binary
+ #gzip -n -9 $(tmp)/usr/share/doc/binary/changelog
+ install -d $(tmp)/DEBIAN
+ install -m 755 debian/postinst $(tmp)/DEBIAN
+ install -m 644 debian/conffiles $(tmp)/DEBIAN
+
+ install -d $(tmp)/usr/share/applications
+ install -m 644 debian/hello.desktop \
+ $(tmp)/usr/share/applications/hello.desktop
+ install -m 755 debian/goodbye.desktop \
+ $(tmp)/usr/share/applications/goodbye.desktop
+
+ # should be ok...
+ echo boe > $(tmp)/usr/bar
+ ln $(tmp)/usr/bar $(tmp)/usr/foo
+ # but this isn't
+ echo boe > $(tmp)/usr/bar2
+ ln $(tmp)/usr/bar2 $(tmp)/usr/share/baz
+
+ dd if=/dev/zero of=$(tmp)/usr/share/binary/largefile bs=1024 count=4000
+
+ install -d debian/binary-data/DEBIAN
+ install -d debian/binary-data/usr/share/doc
+ ln -s binary debian/binary-data/usr/share/doc/binary-data
+
+ dpkg-shlibdeps $(tmp)/usr/bin/hello
+ dpkg-gencontrol -pbinary -isp
+ dpkg-gencontrol -pbinary-data -Pdebian/binary-data -isp
+
+ dpkg --build debian/tmp ..
+ dpkg --build debian/binary-data ..
+
+binary: binary-arch
+
+.PHONY: build-arch build binary-arch binary clean
diff --git a/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/templates b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/templates
new file mode 100644
index 0000000..3d92861
--- /dev/null
+++ b/t/recipes/checks/menu-format/legacy-binary/build-spec/debian/templates
@@ -0,0 +1,16 @@
+# The debconf templates defined here are the sort that you'd use if
+# providing a wordlist and an ispell dictionary for the language
+# "perl". This shouldn't trigger warnings about not using debconf-po.
+
+Template: shared/packages-ispell
+Type: text
+Description:
+
+Template: shared/packages-wordlist
+Type: text
+Description:
+
+Template: miscfiles/languages
+Type: text
+Default: perl (Pathologically Eclectic Rubbish Lister)
+Description:
diff --git a/t/recipes/checks/menu-format/legacy-binary/build-spec/fill-values b/t/recipes/checks/menu-format/legacy-binary/build-spec/fill-values
new file mode 100644
index 0000000..b503871
--- /dev/null
+++ b/t/recipes/checks/menu-format/legacy-binary/build-spec/fill-values
@@ -0,0 +1,5 @@
+Skeleton: upload-non-native
+Testname: legacy-binary
+Source: binary
+Version: 4-1.1
+Description: Legacy test "binary"
diff --git a/t/recipes/checks/menu-format/legacy-binary/build-spec/orig/INSTALL b/t/recipes/checks/menu-format/legacy-binary/build-spec/orig/INSTALL
new file mode 100644
index 0000000..3b50ea9
--- /dev/null
+++ b/t/recipes/checks/menu-format/legacy-binary/build-spec/orig/INSTALL
@@ -0,0 +1,176 @@
+Basic Installation
+==================
+
+ These are generic installation instructions.
+
+ The `configure' shell script attempts to guess correct values for
+various system-dependent variables used during compilation. It uses
+those values to create a `Makefile' in each directory of the package.
+It may also create one or more `.h' files containing system-dependent
+definitions. Finally, it creates a shell script `config.status' that
+you can run in the future to recreate the current configuration, a file
+`config.cache' that saves the results of its tests to speed up
+reconfiguring, and a file `config.log' containing compiler output
+(useful mainly for debugging `configure').
+
+ If you need to do unusual things to compile the package, please try
+to figure out how `configure' could check whether to do them, and mail
+diffs or instructions to the address given in the `README' so they can
+be considered for the next release. If at some point `config.cache'
+contains results you don't want to keep, you may remove or edit it.
+
+ The file `configure.in' is used to create `configure' by a program
+called `autoconf'. You only need `configure.in' if you want to change
+it or regenerate `configure' using a newer version of `autoconf'.
+
+The simplest way to compile this package is:
+
+ 1. `cd' to the directory containing the package's source code and type
+ `./configure' to configure the package for your system. If you're
+ using `csh' on an old version of System V, you might need to type
+ `sh ./configure' instead to prevent `csh' from trying to execute
+ `configure' itself.
+
+ Running `configure' takes a while. While running, it prints some
+ messages telling which features it is checking for.
+
+ 2. Type `make' to compile the package.
+
+ 3. Optionally, type `make check' to run any self-tests that come with
+ the package.
+
+ 4. Type `make install' to install the programs and any data files and
+ documentation.
+
+ 5. You can remove the program binaries and object files from the
+ source code directory by typing `make clean'. To also remove the
+ files that `configure' created (so you can compile the package for
+ a different kind of computer), type `make distclean'. There is
+ also a `make maintainer-clean' target, but that is intended mainly
+ for the package's developers. If you use it, you may have to get
+ all sorts of other programs in order to regenerate files that came
+ with the distribution.
+
+Compilers and Options
+=====================
+
+ Some systems require unusual options for compilation or linking that
+the `configure' script does not know about. You can give `configure'
+initial values for variables by setting them in the environment. Using
+a Bourne-compatible shell, you can do that on the command line like
+this:
+ CC=c89 CFLAGS=-O2 LIBS=-lposix ./configure
+
+Or on systems that have the `env' program, you can do it like this:
+ env CPPFLAGS=-I/usr/local/include LDFLAGS=-s ./configure
+
+Compiling For Multiple Architectures
+====================================
+
+ You can compile the package for more than one kind of computer at the
+same time, by placing the object files for each architecture in their
+own directory. To do this, you must use a version of `make' that
+supports the `VPATH' variable, such as GNU `make'. `cd' to the
+directory where you want the object files and executables to go and run
+the `configure' script. `configure' automatically checks for the
+source code in the directory that `configure' is in and in `..'.
+
+ If you have to use a `make' that does not supports the `VPATH'
+variable, you have to compile the package for one architecture at a time
+in the source code directory. After you have installed the package for
+one architecture, use `make distclean' before reconfiguring for another
+architecture.
+
+Installation Names
+==================
+
+ By default, `make install' will install the package's files in
+`/usr/local/bin', `/usr/local/man', etc. You can specify an
+installation prefix other than `/usr/local' by giving `configure' the
+option `--prefix=PATH'.
+
+ You can specify separate installation prefixes for
+architecture-specific files and architecture-independent files. If you
+give `configure' the option `--exec-prefix=PATH', the package will use
+PATH as the prefix for installing programs and libraries.
+Documentation and other data files will still use the regular prefix.
+
+ If the package supports it, you can cause programs to be installed
+with an extra prefix or suffix on their names by giving `configure' the
+option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
+
+Optional Features
+=================
+
+ Some packages pay attention to `--enable-FEATURE' options to
+`configure', where FEATURE indicates an optional part of the package.
+They may also pay attention to `--with-PACKAGE' options, where PACKAGE
+is something like `gnu-as' or `x' (for the X Window System). The
+`README' should mention any `--enable-' and `--with-' options that the
+package recognizes.
+
+ For packages that use the X Window System, `configure' can usually
+find the X include and library files automatically, but if it doesn't,
+you can use the `configure' options `--x-includes=DIR' and
+`--x-libraries=DIR' to specify their locations.
+
+Specifying the System Type
+==========================
+
+ There may be some features `configure' can not figure out
+automatically, but needs to determine by the type of host the package
+will run on. Usually `configure' can figure that out, but if it prints
+a message saying it can not guess the host type, give it the
+`--host=TYPE' option. TYPE can either be a short name for the system
+type, such as `sun4', or a canonical name with three fields:
+ CPU-COMPANY-SYSTEM
+
+See the file `config.sub' for the possible values of each field. If
+`config.sub' isn't included in this package, then this package doesn't
+need to know the host type.
+
+ If you are building compiler tools for cross-compiling, you can also
+use the `--target=TYPE' option to select the type of system they will
+produce code for and the `--build=TYPE' option to select the type of
+system on which you are compiling the package.
+
+Sharing Defaults
+================
+
+ If you want to set default values for `configure' scripts to share,
+you can create a site shell script called `config.site' that gives
+default values for variables like `CC', `cache_file', and `prefix'.
+`configure' looks for `PREFIX/share/config.site' if it exists, then
+`PREFIX/etc/config.site' if it exists. Or, you can set the
+`CONFIG_SITE' environment variable to the location of the site script.
+A warning: not all `configure' scripts look for a site script.
+
+Operation Controls
+==================
+
+ `configure' recognizes the following options to control how it
+operates.
+
+`--cache-file=FILE'
+ Use and save the results of the tests in FILE instead of
+ `./config.cache'. Set FILE to `/dev/null' to disable caching, for
+ debugging `configure'.
+
+`--help'
+ Print a summary of the options to `configure', and exit.
+
+`--quiet'
+`--silent'
+`-q'
+ Do not print messages saying which checks are being made.
+
+`--srcdir=DIR'
+ Look for the package's source code in directory DIR. Usually
+ `configure' can determine that directory automatically.
+
+`--version'
+ Print the version of Autoconf used to generate the `configure'
+ script, and exit.
+
+`configure' also accepts some other, not widely useful, options.
+
diff --git a/t/recipes/checks/menu-format/legacy-binary/build-spec/orig/Makefile b/t/recipes/checks/menu-format/legacy-binary/build-spec/orig/Makefile
new file mode 100644
index 0000000..da1dc55
--- /dev/null
+++ b/t/recipes/checks/menu-format/legacy-binary/build-spec/orig/Makefile
@@ -0,0 +1,12 @@
+all: hello hello-static
+
+hello: hello.c
+ gcc hello.c -o hello
+
+hello-static: hello.c
+ gcc -static hello.c -o hello-static
+
+clean:
+ rm -f hello hello-static
+
+distclean: clean
diff --git a/t/recipes/checks/menu-format/legacy-binary/build-spec/orig/hello.c b/t/recipes/checks/menu-format/legacy-binary/build-spec/orig/hello.c
new file mode 100644
index 0000000..2fb04e1
--- /dev/null
+++ b/t/recipes/checks/menu-format/legacy-binary/build-spec/orig/hello.c
@@ -0,0 +1,8 @@
+#include <stdio.h>
+#include <stdlib.h>
+
+int main(int argc, char *argv[]) {
+
+ printf("Hello, World!\n");
+ exit(0);
+}
diff --git a/t/recipes/checks/menu-format/legacy-binary/eval/desc b/t/recipes/checks/menu-format/legacy-binary/eval/desc
new file mode 100644
index 0000000..d95e91d
--- /dev/null
+++ b/t/recipes/checks/menu-format/legacy-binary/eval/desc
@@ -0,0 +1,2 @@
+Testname: legacy-binary
+Check: menu-format
diff --git a/t/recipes/checks/menu-format/legacy-binary/eval/hints b/t/recipes/checks/menu-format/legacy-binary/eval/hints
new file mode 100644
index 0000000..60b22dd
--- /dev/null
+++ b/t/recipes/checks/menu-format/legacy-binary/eval/hints
@@ -0,0 +1,63 @@
+binary (binary): unquoted-string-in-menu-item needs [usr/share/menu/binary:2]
+binary (binary): unquoted-string-in-menu-item needs [usr/share/menu/binary:1]
+binary (binary): unquoted-string-in-menu-item needs [usr/lib/menu/binary:2]
+binary (binary): unquoted-string-in-menu-item needs [usr/lib/menu/binary:1]
+binary (binary): su-wrapper-without--c sux [usr/share/menu/binary:3]
+binary (binary): su-wrapper-without--c sux [usr/lib/menu/binary:3]
+binary (binary): su-wrapper-without--c su-to-root [usr/share/menu/binary:2]
+binary (binary): su-wrapper-without--c su-to-root [usr/lib/menu/binary:2]
+binary (binary): su-wrapper-not-su-to-root sux [usr/share/menu/binary:3]
+binary (binary): su-wrapper-not-su-to-root sux [usr/lib/menu/binary:3]
+binary (binary): su-wrapper-not-su-to-root kdesu [usr/share/applications/hello.desktop]
+binary (binary): su-to-root-with-usr-sbin [usr/share/menu/binary:4]
+binary (binary): su-to-root-with-usr-sbin [usr/lib/menu/binary:4]
+binary (binary): non-wm-module-in-wm-modules-menu-section wm [usr/share/menu/binary:22]
+binary (binary): non-wm-module-in-wm-modules-menu-section wm [usr/lib/menu/binary:22]
+binary (binary): non-wm-in-windowmanager-menu-section x11 [usr/share/menu/binary:4]
+binary (binary): non-wm-in-windowmanager-menu-section x11 [usr/lib/menu/binary:4]
+binary (binary): menu-item-uses-windowmanagers-section [usr/share/menu/binary:13]
+binary (binary): menu-item-uses-windowmanagers-section [usr/lib/menu/binary:13]
+binary (binary): menu-item-uses-apps-section [usr/share/menu/binary:7]
+binary (binary): menu-item-uses-apps-section [usr/lib/menu/binary:7]
+binary (binary): menu-item-needs-tag-has-unknown-value wm [usr/share/menu/binary:5]
+binary (binary): menu-item-needs-tag-has-unknown-value wm [usr/lib/menu/binary:5]
+binary (binary): menu-item-missing-required-tag section [usr/share/menu/binary:1]
+binary (binary): menu-item-missing-required-tag section [usr/lib/menu/binary:1]
+binary (binary): menu-item-missing-required-tag needs [usr/share/menu/binary:6]
+binary (binary): menu-item-missing-required-tag needs [usr/lib/menu/binary:6]
+binary (binary): menu-item-creates-new-section WindowManagers/Modules [usr/share/menu/binary:13]
+binary (binary): menu-item-creates-new-section WindowManagers/Modules [usr/lib/menu/binary:13]
+binary (binary): menu-item-creates-new-section Apps/System [usr/share/menu/binary:7]
+binary (binary): menu-item-creates-new-section Apps/System [usr/lib/menu/binary:7]
+binary (binary): menu-item-creates-new-section Applications/System [usr/share/menu/binary:2]
+binary (binary): menu-item-creates-new-section Applications/System [usr/lib/menu/binary:2]
+binary (binary): menu-command-not-in-package xfdisk [usr/share/menu/binary:4]
+binary (binary): menu-command-not-in-package xfdisk [usr/lib/menu/binary:4]
+binary (binary): menu-command-not-in-package imnothere [usr/share/menu/binary:7]
+binary (binary): menu-command-not-in-package imnothere [usr/share/menu/binary:18]
+binary (binary): menu-command-not-in-package imnothere [usr/lib/menu/binary:7]
+binary (binary): menu-command-not-in-package imnothere [usr/lib/menu/binary:18]
+binary (binary): menu-command-not-in-package cfdisk [usr/share/menu/binary:20]
+binary (binary): menu-command-not-in-package cfdisk [usr/lib/menu/binary:20]
+binary (binary): executable-desktop-file 0755 [usr/share/applications/goodbye.desktop]
+binary (binary): desktop-entry-uses-reserved-category Screensaver [usr/share/applications/goodbye.desktop]
+binary (binary): desktop-entry-missing-required-key Name [usr/share/applications/goodbye.desktop]
+binary (binary): desktop-entry-lacks-keywords-entry [usr/share/applications/hello.desktop]
+binary (binary): desktop-entry-lacks-keywords-entry [usr/share/applications/goodbye.desktop]
+binary (binary): desktop-entry-lacks-icon-entry [usr/share/applications/goodbye.desktop]
+binary (binary): desktop-entry-invalid-category WeirdStuff [usr/share/applications/goodbye.desktop]
+binary (binary): desktop-entry-file-has-crs [usr/share/applications/hello.desktop:7]
+binary (binary): desktop-entry-contains-unknown-key icon [usr/share/applications/goodbye.desktop:7]
+binary (binary): desktop-entry-contains-unknown-key SpecialTag [usr/share/applications/goodbye.desktop:5]
+binary (binary): desktop-entry-contains-encoding-key Encoding [usr/share/applications/hello.desktop:13]
+binary (binary): desktop-entry-contains-encoding-key Encoding [usr/share/applications/goodbye.desktop:11]
+binary (binary): desktop-contains-deprecated-key [usr/share/applications/hello.desktop:4]
+binary (binary): desktop-command-not-in-package goodbye [usr/share/applications/goodbye.desktop]
+binary (binary): command-in-menu-file-and-desktop-file hello [usr/share/menu/binary:5]
+binary (binary): command-in-menu-file-and-desktop-file hello [usr/share/menu/binary:24]
+binary (binary): command-in-menu-file-and-desktop-file hello [usr/share/menu/binary:22]
+binary (binary): command-in-menu-file-and-desktop-file hello [usr/share/menu/binary:21]
+binary (binary): command-in-menu-file-and-desktop-file hello [usr/lib/menu/binary:5]
+binary (binary): command-in-menu-file-and-desktop-file hello [usr/lib/menu/binary:24]
+binary (binary): command-in-menu-file-and-desktop-file hello [usr/lib/menu/binary:22]
+binary (binary): command-in-menu-file-and-desktop-file hello [usr/lib/menu/binary:21]
diff --git a/t/recipes/checks/menu-format/legacy-binary/eval/post-test b/t/recipes/checks/menu-format/legacy-binary/eval/post-test
new file mode 100644
index 0000000..3deefd5
--- /dev/null
+++ b/t/recipes/checks/menu-format/legacy-binary/eval/post-test
@@ -0,0 +1,3 @@
+s/arch-dep-package-has-big-usr-share .*kB .*%/arch-dep-package-has-big-usr-share/
+/: hardening-.*/ d
+s/\(current is ([0-9]+\.)+[0-9]\)/(current is CURRENT)/
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/debian/install b/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/debian/install
new file mode 100644
index 0000000..ae6f6ea
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/debian/install
@@ -0,0 +1,8 @@
+crlf.desktop usr/share/applications
+environments.desktop usr/share/applications
+general.desktop usr/share/applications
+missing.desktop usr/share/applications
+reserved-bad.desktop usr/share/applications
+reserved.desktop usr/share/applications
+link.desktop usr/share/applications
+directory.desktop usr/share/applications
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/debian/rules b/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/debian/rules
new file mode 100755
index 0000000..704ddff
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/debian/rules
@@ -0,0 +1,10 @@
+#!/usr/bin/make -f
+
+pkg = $(shell dh_listpackages)
+
+%:
+ dh $@
+
+override_dh_fixperms:
+ dh_fixperms
+ chmod a+x debian/$(pkg)/usr/share/applications/general.desktop
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/fill-values b/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/fill-values
new file mode 100644
index 0000000..62ad777
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/fill-values
@@ -0,0 +1,3 @@
+Skeleton: upload-native
+Testname: menu-format-desktop-general
+Description: Test desktop file tags
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/crlf.desktop b/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/crlf.desktop
new file mode 100644
index 0000000..4e53c3a
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/crlf.desktop
@@ -0,0 +1,7 @@
+[Desktop Entry]
+Name=general
+Comment=An entirely correct desktop entry
+Type=Application
+Categories=Development;Building;
+Icon=foo
+Keywords=Foobar
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/directory.desktop b/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/directory.desktop
new file mode 100644
index 0000000..0a450bc
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/directory.desktop
@@ -0,0 +1,5 @@
+[Desktop Entry]
+Type=Directory
+Name=link
+Icon=link
+Comment=This is Type=Directory and thus does not require a Keywords key
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/environments.desktop b/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/environments.desktop
new file mode 100644
index 0000000..51aa674
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/environments.desktop
@@ -0,0 +1,9 @@
+[Desktop Entry]
+Name=environments
+Type=Application
+Comment=Incorrectly limited to particular environments
+Categories=Development;
+Exec=foo
+OnlyShowIn=GNOME;KDE;
+Icon=foo
+Keywords=Golf
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/general.desktop b/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/general.desktop
new file mode 100644
index 0000000..f1ef3bd
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/general.desktop
@@ -0,0 +1,13 @@
+[Desktop Entry]
+Name=general
+Name=general
+Comment=Various general errors
+Type=Application
+Foo=Bar
+Encoding=UTF-8
+Categories=Building;Lintian;
+Terminal=true
+TerminalOptions=-g 80x25
+Exec=foo
+#missing Icon
+#missing Keywords
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/link.desktop b/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/link.desktop
new file mode 100644
index 0000000..9f20d7c
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/link.desktop
@@ -0,0 +1,6 @@
+[Desktop Entry]
+Type=Link
+Name=link
+Icon=link
+Comment=This is Type=Link and thus does not require a Keywords key
+URL=http://example.com/
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/missing.desktop b/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/missing.desktop
new file mode 100644
index 0000000..6a07c8f
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/missing.desktop
@@ -0,0 +1,5 @@
+[Desktop Entry]
+Name=foo
+Comment=This entry has no Application
+Categories=Development;
+Exec=foo
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/reserved-bad.desktop b/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/reserved-bad.desktop
new file mode 100644
index 0000000..a0b71e1
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/reserved-bad.desktop
@@ -0,0 +1,8 @@
+[Desktop Entry]
+Name=reserved
+Comment=Entry in a reserved category (incorrect)
+Type=Application
+Categories=Screensaver;
+Exec=foo
+Icon=foo
+Keywords=Fun
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/reserved.desktop b/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/reserved.desktop
new file mode 100644
index 0000000..9256014
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-general/build-spec/orig/reserved.desktop
@@ -0,0 +1,9 @@
+[Desktop Entry]
+Name=reserved
+Comment=Entry in a reserved category (correct)
+Type=Application
+Categories=Screensaver;
+Exec=foo
+OnlyShowIn=GNOME;KDE;
+Icon=foo
+Keywords=Blur
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-general/eval/desc b/t/recipes/checks/menu-format/menu-format-desktop-general/eval/desc
new file mode 100644
index 0000000..15a1c2a
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-general/eval/desc
@@ -0,0 +1,3 @@
+Testname: menu-format-desktop-general
+See-Also: Debian Bug#537737
+Check: menu-format
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-general/eval/hints b/t/recipes/checks/menu-format/menu-format-desktop-general/eval/hints
new file mode 100644
index 0000000..fd3fa4a
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-general/eval/hints
@@ -0,0 +1,16 @@
+menu-format-desktop-general (binary): executable-desktop-file 0755 [usr/share/applications/general.desktop]
+menu-format-desktop-general (binary): duplicate-key-in-desktop Name [usr/share/applications/general.desktop:3]
+menu-format-desktop-general (binary): desktop-entry-uses-reserved-category Screensaver [usr/share/applications/reserved-bad.desktop]
+menu-format-desktop-general (binary): desktop-entry-limited-to-environments [usr/share/applications/environments.desktop]
+menu-format-desktop-general (binary): desktop-entry-lacks-main-category [usr/share/applications/general.desktop]
+menu-format-desktop-general (binary): desktop-entry-lacks-keywords-entry [usr/share/applications/general.desktop]
+menu-format-desktop-general (binary): desktop-entry-lacks-icon-entry [usr/share/applications/general.desktop]
+menu-format-desktop-general (binary): desktop-entry-invalid-category Lintian [usr/share/applications/general.desktop]
+menu-format-desktop-general (binary): desktop-entry-file-has-crs [usr/share/applications/crlf.desktop:1]
+menu-format-desktop-general (binary): desktop-entry-contains-unknown-key Foo [usr/share/applications/general.desktop:6]
+menu-format-desktop-general (binary): desktop-entry-contains-encoding-key Encoding [usr/share/applications/general.desktop:7]
+menu-format-desktop-general (binary): desktop-entry-contains-deprecated-key TerminalOptions [usr/share/applications/general.desktop:10]
+menu-format-desktop-general (binary): desktop-command-not-in-package foo [usr/share/applications/reserved.desktop]
+menu-format-desktop-general (binary): desktop-command-not-in-package foo [usr/share/applications/reserved-bad.desktop]
+menu-format-desktop-general (binary): desktop-command-not-in-package foo [usr/share/applications/general.desktop]
+menu-format-desktop-general (binary): desktop-command-not-in-package foo [usr/share/applications/environments.desktop]
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/debian/control.in b/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/debian/control.in
new file mode 100644
index 0000000..672ac84
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/debian/control.in
@@ -0,0 +1,16 @@
+Source: [% $source %]
+Priority: optional
+Section: devel
+Maintainer: [% $author %]
+Standards-Version: [% $standards_version %]
+Build-Depends: [% $build_depends %]
+Rules-Requires-Root: no
+
+Package: menu-mime
+Architecture: [% $package_architecture %]
+Depends: ${misc:Depends}
+Description: [% $description %]
+ This is a test package designed to exercise some feature or tag of
+ Lintian. It is part of the Lintian test suite and may do very odd
+ things. It should not be installed like a regular package. It may
+ be an empty package.
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/debian/menu-mime.install b/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/debian/menu-mime.install
new file mode 100644
index 0000000..00850a0
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/debian/menu-mime.install
@@ -0,0 +1,2 @@
+*.desktop usr/share/applications
+pargs usr/bin
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/debian/menu-mime.manpages b/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/debian/menu-mime.manpages
new file mode 100644
index 0000000..6fb56bc
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/debian/menu-mime.manpages
@@ -0,0 +1 @@
+pargs.1
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/fill-values b/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/fill-values
new file mode 100644
index 0000000..3233112
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/fill-values
@@ -0,0 +1,4 @@
+Skeleton: upload-native
+Testname: menu-format-desktop-mimetype
+Section: doc
+Description: Check mime-related issues in desktop files
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/orig/Makefile b/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/orig/Makefile
new file mode 100644
index 0000000..5b475b1
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/orig/Makefile
@@ -0,0 +1,6 @@
+all: pargs
+ pod2man --section=1 pargs pargs.1
+
+clean:
+ rm -f pargs*.1
+
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/orig/bar.desktop b/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/orig/bar.desktop
new file mode 100644
index 0000000..20d591d
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/orig/bar.desktop
@@ -0,0 +1,10 @@
+[Desktop Entry]
+Name=GNU bar
+GenericName=bar
+Comment=A bar test entry for Lintian
+Type=Application
+Categories=Game;BoardGame;GTK;
+MimeType=application/bar;
+Keywords=Lintian
+Icon=foo
+Exec=pargs %U
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/orig/foo.desktop b/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/orig/foo.desktop
new file mode 100644
index 0000000..0e6c1fb
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/orig/foo.desktop
@@ -0,0 +1,9 @@
+[Desktop Entry]
+Name=GNU Foo
+GenericName=Foo
+Comment=A foo test entry for Lintian
+Type=Application
+Categories=Game;BoardGame;GTK;
+MimeType=application/foo;
+Icon=foo
+Keywords=Lintian
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/orig/pargs b/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/orig/pargs
new file mode 100644
index 0000000..5a0017c
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-mimetype/build-spec/orig/pargs
@@ -0,0 +1,22 @@
+#!/usr/bin/perl
+
+use strict;
+use warnings;
+
+print join("\n", @ARGV), "\n";
+exit 0;
+
+=head1 NAME
+
+pargs - print arguments (similar to echo)
+
+=head1 SYNOPSIS
+
+pargs [...]
+
+=head1 DESCRIPTION
+
+Prints all arguments separated by newlines.
+
+=cut
+
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-mimetype/eval/desc b/t/recipes/checks/menu-format/menu-format-desktop-mimetype/eval/desc
new file mode 100644
index 0000000..43935ef
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-mimetype/eval/desc
@@ -0,0 +1,3 @@
+Testname: menu-format-desktop-mimetype
+See-Also: Debian Bug#488832, Debian Bug#525133, #757383, #760677
+Check: menu-format
diff --git a/t/recipes/checks/menu-format/menu-format-desktop-mimetype/eval/hints b/t/recipes/checks/menu-format/menu-format-desktop-mimetype/eval/hints
new file mode 100644
index 0000000..0eec47f
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-desktop-mimetype/eval/hints
@@ -0,0 +1 @@
+menu-mime (binary): desktop-mime-but-no-exec-code [usr/share/applications/foo.desktop]
diff --git a/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/control.in b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/control.in
new file mode 100644
index 0000000..10303b5
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/control.in
@@ -0,0 +1,51 @@
+Source: [% $source %]
+Priority: optional
+Section: devel
+Maintainer: [% $author %]
+Standards-Version: [% $standards_version %]
+Build-Depends: [% $build_depends %]
+Rules-Requires-Root: no
+
+Package: menu-none
+Architecture: all
+Depends: ${misc:Depends}
+Description: [% $description %] (no icon)
+ This is a test package designed to exercise some feature or tag of
+ Lintian. It is part of the Lintian test suite and may do very odd
+ things. It should not be installed like a regular package. It may
+ be an empty package.
+ .
+ Test for "none" icon and missing icons.
+
+Package: menu-cmd
+Architecture: all
+Depends: ${misc:Depends}
+Description: [% $description %] (cmd)
+ This is a test package designed to exercise some feature or tag of
+ Lintian. It is part of the Lintian test suite and may do very odd
+ things. It should not be installed like a regular package. It may
+ be an empty package.
+ .
+ Test for command not being in the package.
+
+Package: menu-broken
+Architecture: all
+Depends: ${misc:Depends}
+Description: [% $description %] (broken)
+ This is a test package designed to exercise some feature or tag of
+ Lintian. It is part of the Lintian test suite and may do very odd
+ things. It should not be installed like a regular package. It may
+ be an empty package.
+ .
+ Test for broken menu file.
+
+Package: menu-section
+Architecture: all
+Depends: ${misc:Depends}
+Description: [% $description %] (section)
+ This is a test package designed to exercise some feature or tag of
+ Lintian. It is part of the Lintian test suite and may do very odd
+ things. It should not be installed like a regular package. It may
+ be an empty package.
+ .
+ Test for menu file with weird sections.
diff --git a/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-broken.install b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-broken.install
new file mode 100644
index 0000000..f352ad9
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-broken.install
@@ -0,0 +1 @@
+pargs-broken usr/bin
diff --git a/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-broken.manpages b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-broken.manpages
new file mode 100644
index 0000000..9f8d467
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-broken.manpages
@@ -0,0 +1 @@
+pargs-broken.1
diff --git a/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-broken.menu b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-broken.menu
new file mode 100644
index 0000000..fee3e7f
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-broken.menu
@@ -0,0 +1,12 @@
+?package(menu-broken):needs="X11" section="Applications/Programming"\
+ title="pargs (missing slash)" command="/usr/bin/pargs-broken"\
+ longtitle="Argument printer (bad-test)"
+ icon="none" newtag=unquoted-value
+?package(wrong-package):needs="X11" section="Applications/Programming"\
+ title="pargs (wrong pkg)" command="/usr/bin/pargs-broken"\
+ longtitle="Argument printer"
+?package(menu-broken):needs="X11" section="Applications/Programming"\
+ title="pargs (dup+unparse)" command="/usr/bin/pargs-broken"\
+ longtitle="Argument printer"\
+ longtitle="Argument printer"\
+ unparseable-stuff
diff --git a/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-cmd.install b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-cmd.install
new file mode 100644
index 0000000..b8f1c81
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-cmd.install
@@ -0,0 +1,2 @@
+*.xpm usr/share/pixmaps/
+pargs.png usr/share/pixmaps/
diff --git a/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-cmd.menu b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-cmd.menu
new file mode 100644
index 0000000..73bc14c
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-cmd.menu
@@ -0,0 +1,4 @@
+?package(menu-cmd):needs="X11" section="Applications/Programming"\
+ title="pargs (png icon)" command="/usr/bin/not-here"\
+ longtitle="Argument printer" icon16x16="/usr/share/pixmaps/pargs.png" \
+ icon="/usr/share/pixmaps/broken.xpm" icon32x32="/usr/share/pixmaps/too-large.xpm"
diff --git a/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-none.install b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-none.install
new file mode 100644
index 0000000..bf2c0f6
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-none.install
@@ -0,0 +1 @@
+pargs usr/bin
diff --git a/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-none.manpages b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-none.manpages
new file mode 100644
index 0000000..6fb56bc
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-none.manpages
@@ -0,0 +1 @@
+pargs.1
diff --git a/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-none.menu b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-none.menu
new file mode 100644
index 0000000..4bd3892
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-none.menu
@@ -0,0 +1,16 @@
+?package(menu-none):needs="X11" section="Applications/Programming"\
+ title="pargs (icon none)" command="/usr/bin/pargs"\
+ longtitle="Argument printer"\
+ icon="none"
+?package(menu-none):needs="X11" section="Applications/Programming"\
+ title="pargs (mis. icon)" command="/usr/bin/pargs"\
+ longtitle="Argument printer"\
+ icon="/usr/share/menu-none/non-existent.xpm"\
+ icon32x32="/usr/share/menu-none/non-existent32.xpm"\
+ icon16x16="/usr/share/menu-none/non-existent16.xpm"
+?package(menu-none):needs="X11" section="Applications/Programming"\
+ title="pargs (rel. icon)" command="/usr/bin/pargs"\
+ longtitle="Argument printer"\
+ icon="non-existent.xpm"\
+ icon32x32="non-existent32.xpm"\
+ icon16x16="non-existent16.xpm"
diff --git a/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-section.install b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-section.install
new file mode 100644
index 0000000..4cf0ec4
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-section.install
@@ -0,0 +1,2 @@
+pargs-section usr/bin
+pargs.desktop usr/share/applications
diff --git a/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-section.manpages b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-section.manpages
new file mode 100644
index 0000000..bfc1a5b
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-section.manpages
@@ -0,0 +1 @@
+pargs-section.1
diff --git a/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-section.menu b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-section.menu
new file mode 100644
index 0000000..f6d6893
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-general/build-spec/debian/menu-section.menu
@@ -0,0 +1,15 @@
+?package(menu-section):needs="X11" section="Root"\
+ title="pargs (new root)" command="/usr/bin/pargs-section"\
+ longtitle="Argument printer"
+?package(menu-section):needs="X11" section="Apps/Games/Toys"\
+ title="pargs (apps/games)" command="/usr/bin/pargs-section"\
+ longtitle="Argument printer"
+?package(menu-section):needs="X11" section="Games"\
+ title="pargs (games)" command="/usr/bin/pargs-section"\
+ longtitle="Argument printer"
+?package(menu-section):needs="X11" section="Apps/Programming"\
+ title="pargs (apps/prog)" command="/usr/bin/pargs-section"\
+ longtitle="Argument printer"
+?package(menu-section):needs="X11" section="WindowManagers/Programming"\
+ title="pargs (vm)" command="/usr/bin/pargs-section"\
+ longtitle="Argument printer"
diff --git a/t/recipes/checks/menu-format/menu-format-general/build-spec/fill-values b/t/recipes/checks/menu-format/menu-format-general/build-spec/fill-values
new file mode 100644
index 0000000..5c96d32
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-general/build-spec/fill-values
@@ -0,0 +1,3 @@
+Skeleton: upload-native
+Testname: menu-format-general
+Description: Test menu file tags
diff --git a/t/recipes/checks/menu-format/menu-format-general/build-spec/orig/Makefile b/t/recipes/checks/menu-format/menu-format-general/build-spec/orig/Makefile
new file mode 100644
index 0000000..2754f69
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-general/build-spec/orig/Makefile
@@ -0,0 +1,11 @@
+all: pargs
+ sed s/pargs/pargs-broken/ pargs > pargs-broken
+ sed s/pargs/pargs-section/ pargs > pargs-section
+ pod2man --section=1 pargs pargs.1
+ pod2man --section=1 pargs-broken pargs-broken.1
+ pod2man --section=1 pargs-section pargs-section.1
+
+
+clean:
+ rm -f pargs*.1
+ rm -f pargs-*
diff --git a/t/recipes/checks/menu-format/menu-format-general/build-spec/orig/broken.xpm b/t/recipes/checks/menu-format/menu-format-general/build-spec/orig/broken.xpm
new file mode 100644
index 0000000..2fa612c
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-general/build-spec/orig/broken.xpm
@@ -0,0 +1 @@
+/* Pretend to be an XPM file without being it */
diff --git a/t/recipes/checks/menu-format/menu-format-general/build-spec/orig/pargs b/t/recipes/checks/menu-format/menu-format-general/build-spec/orig/pargs
new file mode 100644
index 0000000..5a0017c
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-general/build-spec/orig/pargs
@@ -0,0 +1,22 @@
+#!/usr/bin/perl
+
+use strict;
+use warnings;
+
+print join("\n", @ARGV), "\n";
+exit 0;
+
+=head1 NAME
+
+pargs - print arguments (similar to echo)
+
+=head1 SYNOPSIS
+
+pargs [...]
+
+=head1 DESCRIPTION
+
+Prints all arguments separated by newlines.
+
+=cut
+
diff --git a/t/recipes/checks/menu-format/menu-format-general/build-spec/orig/pargs.desktop b/t/recipes/checks/menu-format/menu-format-general/build-spec/orig/pargs.desktop
new file mode 100644
index 0000000..b84ecf2
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-general/build-spec/orig/pargs.desktop
@@ -0,0 +1,8 @@
+[Desktop Entry]
+Name=pargs
+Type=Application
+Comment=Argument Printer
+Categories=Development;
+Keywords=Argument;Printer;
+Icon=foo
+Exec=pargs-section
diff --git a/t/recipes/checks/menu-format/menu-format-general/build-spec/orig/pargs.png b/t/recipes/checks/menu-format/menu-format-general/build-spec/orig/pargs.png
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-general/build-spec/orig/pargs.png
diff --git a/t/recipes/checks/menu-format/menu-format-general/build-spec/orig/too-large.xpm b/t/recipes/checks/menu-format/menu-format-general/build-spec/orig/too-large.xpm
new file mode 100644
index 0000000..1403c5d
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-general/build-spec/orig/too-large.xpm
@@ -0,0 +1,10 @@
+/* XPM */
+
+/*
+ This is a fake XPM file - it has just enough to fool Lintian into
+ believing this is a 256x256 image...
+ */
+
+ "256 256 10 10"
+
+ /* Lintian is not too bright... :P */
diff --git a/t/recipes/checks/menu-format/menu-format-general/eval/desc b/t/recipes/checks/menu-format/menu-format-general/eval/desc
new file mode 100644
index 0000000..b332370
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-general/eval/desc
@@ -0,0 +1,2 @@
+Testname: menu-format-general
+Check: menu-format
diff --git a/t/recipes/checks/menu-format/menu-format-general/eval/hints b/t/recipes/checks/menu-format/menu-format-general/eval/hints
new file mode 100644
index 0000000..9ad6e14
--- /dev/null
+++ b/t/recipes/checks/menu-format/menu-format-general/eval/hints
@@ -0,0 +1,30 @@
+menu-section (binary): non-wm-in-windowmanager-menu-section x11 [usr/share/menu/menu-section:15]
+menu-section (binary): menu-item-uses-windowmanagers-section [usr/share/menu/menu-section:15]
+menu-section (binary): menu-item-uses-apps-section [usr/share/menu/menu-section:12]
+menu-section (binary): menu-item-uses-apps-games-section [usr/share/menu/menu-section:6]
+menu-section (binary): menu-item-creates-new-section WindowManagers/Programming [usr/share/menu/menu-section:15]
+menu-section (binary): menu-item-creates-new-section Games [usr/share/menu/menu-section:9]
+menu-section (binary): menu-item-creates-new-root-section Root [usr/share/menu/menu-section:3]
+menu-section (binary): command-in-menu-file-and-desktop-file pargs-section [usr/share/menu/menu-section:9]
+menu-section (binary): command-in-menu-file-and-desktop-file pargs-section [usr/share/menu/menu-section:6]
+menu-section (binary): command-in-menu-file-and-desktop-file pargs-section [usr/share/menu/menu-section:3]
+menu-section (binary): command-in-menu-file-and-desktop-file pargs-section [usr/share/menu/menu-section:15]
+menu-section (binary): command-in-menu-file-and-desktop-file pargs-section [usr/share/menu/menu-section:12]
+menu-none (binary): menu-item-uses-icon-none icon [usr/share/menu/menu-none:4]
+menu-none (binary): menu-icon-uses-relative-path icon32x32 non-existent32.xpm [usr/share/menu/menu-none:16]
+menu-none (binary): menu-icon-uses-relative-path icon16x16 non-existent16.xpm [usr/share/menu/menu-none:16]
+menu-none (binary): menu-icon-uses-relative-path icon non-existent.xpm [usr/share/menu/menu-none:16]
+menu-none (binary): menu-icon-missing icon32x32 usr/share/menu-none/non-existent32.xpm [usr/share/menu/menu-none:10]
+menu-none (binary): menu-icon-missing icon32x32 non-existent32.xpm [usr/share/menu/menu-none:16]
+menu-none (binary): menu-icon-missing icon16x16 usr/share/menu-none/non-existent16.xpm [usr/share/menu/menu-none:10]
+menu-none (binary): menu-icon-missing icon16x16 non-existent16.xpm [usr/share/menu/menu-none:16]
+menu-none (binary): menu-icon-missing icon usr/share/menu-none/non-existent.xpm [usr/share/menu/menu-none:10]
+menu-none (binary): menu-icon-missing icon non-existent.xpm [usr/share/menu/menu-none:16]
+menu-cmd (binary): menu-icon-too-big icon32x32 usr/share/pixmaps/too-large.xpm: 256x256 > 32x32 [usr/share/menu/menu-cmd:4]
+menu-cmd (binary): menu-icon-not-in-xpm-format icon16x16 usr/share/pixmaps/pargs.png [usr/share/menu/menu-cmd:4]
+menu-cmd (binary): menu-icon-cannot-be-parsed icon usr/share/pixmaps/broken.xpm: looking for XPM header [usr/share/menu/menu-cmd:4]
+menu-cmd (binary): menu-command-not-in-package usr/bin/not-here [usr/share/menu/menu-cmd:4]
+menu-broken (binary): unparsable-menu-item [usr/share/menu/menu-broken:12]
+menu-broken (binary): pkg-not-in-package-test wrong-package [usr/share/menu/menu-broken:7]
+menu-broken (binary): duplicate-tag-in-menu longtitle [usr/share/menu/menu-broken:12]
+menu-broken (binary): bad-test-in-menu-item [usr/share/menu/menu-broken:4]
diff --git a/t/recipes/checks/menu-format/unknown-menu-tag/build-spec/debian/install b/t/recipes/checks/menu-format/unknown-menu-tag/build-spec/debian/install
new file mode 100644
index 0000000..c2ba969
--- /dev/null
+++ b/t/recipes/checks/menu-format/unknown-menu-tag/build-spec/debian/install
@@ -0,0 +1 @@
+test-menu usr/share/menu
diff --git a/t/recipes/checks/menu-format/unknown-menu-tag/build-spec/debian/postinst b/t/recipes/checks/menu-format/unknown-menu-tag/build-spec/debian/postinst
new file mode 100644
index 0000000..024178d
--- /dev/null
+++ b/t/recipes/checks/menu-format/unknown-menu-tag/build-spec/debian/postinst
@@ -0,0 +1,11 @@
+#!/bin/sh
+set -e
+
+# Checks that the maintainer script checks for the existence of programs that
+# it calls. This should produce no warnings except a bashism warning about
+# using type, a warning about the deprecated wm-menu-config invocation, and a
+# warning for calling the deprecated install-docs outside of a trigger.
+
+if [ -x /usr/bin/update-menus ] ; then update-menus ; fi
+
+#DEBHELPER#
diff --git a/t/recipes/checks/menu-format/unknown-menu-tag/build-spec/debian/postrm b/t/recipes/checks/menu-format/unknown-menu-tag/build-spec/debian/postrm
new file mode 100644
index 0000000..c2274f3
--- /dev/null
+++ b/t/recipes/checks/menu-format/unknown-menu-tag/build-spec/debian/postrm
@@ -0,0 +1,7 @@
+#!/bin/sh
+set -e
+if type update-menus >/dev/null 2>&1 ; then
+ update-menus
+fi
+
+#DEBHELPER#
diff --git a/t/recipes/checks/menu-format/unknown-menu-tag/build-spec/fill-values b/t/recipes/checks/menu-format/unknown-menu-tag/build-spec/fill-values
new file mode 100644
index 0000000..3a69155
--- /dev/null
+++ b/t/recipes/checks/menu-format/unknown-menu-tag/build-spec/fill-values
@@ -0,0 +1,3 @@
+Testname: unknown-menu-tag
+Skeleton: upload-native
+Description: Test with a menu file that contains an unknown tag
diff --git a/t/recipes/checks/menu-format/unknown-menu-tag/build-spec/orig/test-menu b/t/recipes/checks/menu-format/unknown-menu-tag/build-spec/orig/test-menu
new file mode 100644
index 0000000..a410949
--- /dev/null
+++ b/t/recipes/checks/menu-format/unknown-menu-tag/build-spec/orig/test-menu
@@ -0,0 +1,6 @@
+?package(unknown-menu-tag):\
+ section="Applications/Programming"\
+ needs="text"\
+ title="Test menu entry"\
+ command="/usr/bin/test-script" \
+ custom="Custom entry"
diff --git a/t/recipes/checks/menu-format/unknown-menu-tag/eval/desc b/t/recipes/checks/menu-format/unknown-menu-tag/eval/desc
new file mode 100644
index 0000000..ea9d71a
--- /dev/null
+++ b/t/recipes/checks/menu-format/unknown-menu-tag/eval/desc
@@ -0,0 +1,2 @@
+Testname: unknown-menu-tag
+Check: menu-format
diff --git a/t/recipes/checks/menu-format/unknown-menu-tag/eval/hints b/t/recipes/checks/menu-format/unknown-menu-tag/eval/hints
new file mode 100644
index 0000000..b1d001e
--- /dev/null
+++ b/t/recipes/checks/menu-format/unknown-menu-tag/eval/hints
@@ -0,0 +1,2 @@
+unknown-menu-tag (binary): menu-item-contains-unknown-tag custom [usr/share/menu/test-menu:6]
+unknown-menu-tag (binary): menu-command-not-in-package usr/bin/test-script [usr/share/menu/test-menu:6]
diff --git a/t/recipes/checks/menu-format/whitespace-after-continuation-character/build-spec/debian/install b/t/recipes/checks/menu-format/whitespace-after-continuation-character/build-spec/debian/install
new file mode 100644
index 0000000..c2ba969
--- /dev/null
+++ b/t/recipes/checks/menu-format/whitespace-after-continuation-character/build-spec/debian/install
@@ -0,0 +1 @@
+test-menu usr/share/menu
diff --git a/t/recipes/checks/menu-format/whitespace-after-continuation-character/build-spec/debian/postinst b/t/recipes/checks/menu-format/whitespace-after-continuation-character/build-spec/debian/postinst
new file mode 100644
index 0000000..024178d
--- /dev/null
+++ b/t/recipes/checks/menu-format/whitespace-after-continuation-character/build-spec/debian/postinst
@@ -0,0 +1,11 @@
+#!/bin/sh
+set -e
+
+# Checks that the maintainer script checks for the existence of programs that
+# it calls. This should produce no warnings except a bashism warning about
+# using type, a warning about the deprecated wm-menu-config invocation, and a
+# warning for calling the deprecated install-docs outside of a trigger.
+
+if [ -x /usr/bin/update-menus ] ; then update-menus ; fi
+
+#DEBHELPER#
diff --git a/t/recipes/checks/menu-format/whitespace-after-continuation-character/build-spec/debian/postrm b/t/recipes/checks/menu-format/whitespace-after-continuation-character/build-spec/debian/postrm
new file mode 100644
index 0000000..c2274f3
--- /dev/null
+++ b/t/recipes/checks/menu-format/whitespace-after-continuation-character/build-spec/debian/postrm
@@ -0,0 +1,7 @@
+#!/bin/sh
+set -e
+if type update-menus >/dev/null 2>&1 ; then
+ update-menus
+fi
+
+#DEBHELPER#
diff --git a/t/recipes/checks/menu-format/whitespace-after-continuation-character/build-spec/fill-values b/t/recipes/checks/menu-format/whitespace-after-continuation-character/build-spec/fill-values
new file mode 100644
index 0000000..9edc28d
--- /dev/null
+++ b/t/recipes/checks/menu-format/whitespace-after-continuation-character/build-spec/fill-values
@@ -0,0 +1,3 @@
+Testname: whitespace-after-continuation-character
+Skeleton: upload-native
+Description: Test with a menu file that contains whitespace after a continuation character
diff --git a/t/recipes/checks/menu-format/whitespace-after-continuation-character/build-spec/orig/test-menu b/t/recipes/checks/menu-format/whitespace-after-continuation-character/build-spec/orig/test-menu
new file mode 100644
index 0000000..6bba1aa
--- /dev/null
+++ b/t/recipes/checks/menu-format/whitespace-after-continuation-character/build-spec/orig/test-menu
@@ -0,0 +1,5 @@
+?package(unknown-menu-tag):\
+ section="Applications/Programming"\
+ needs="text"\
+ title="Test menu entry"\
+ command="/usr/bin/test-script"
diff --git a/t/recipes/checks/menu-format/whitespace-after-continuation-character/eval/desc b/t/recipes/checks/menu-format/whitespace-after-continuation-character/eval/desc
new file mode 100644
index 0000000..d6eee4d
--- /dev/null
+++ b/t/recipes/checks/menu-format/whitespace-after-continuation-character/eval/desc
@@ -0,0 +1,2 @@
+Testname: whitespace-after-continuation-character
+Check: menu-format
diff --git a/t/recipes/checks/menu-format/whitespace-after-continuation-character/eval/hints b/t/recipes/checks/menu-format/whitespace-after-continuation-character/eval/hints
new file mode 100644
index 0000000..9bfdf27
--- /dev/null
+++ b/t/recipes/checks/menu-format/whitespace-after-continuation-character/eval/hints
@@ -0,0 +1,3 @@
+whitespace-after-continuation-character (binary): whitespace-after-continuation-character [usr/share/menu/test-menu:5]
+whitespace-after-continuation-character (binary): pkg-not-in-package-test unknown-menu-tag [usr/share/menu/test-menu:5]
+whitespace-after-continuation-character (binary): menu-command-not-in-package usr/bin/test-script [usr/share/menu/test-menu:5]