summaryrefslogtreecommitdiffstats
path: root/t/recipes/checks/init-d/init.d-lsb-headers
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-14 13:42:30 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-14 13:42:30 +0000
commit75808db17caf8b960b351e3408e74142f4c85aac (patch)
tree7989e9c09a4240248bf4658a22208a0a52d991c4 /t/recipes/checks/init-d/init.d-lsb-headers
parentInitial commit. (diff)
downloadlintian-75808db17caf8b960b351e3408e74142f4c85aac.tar.xz
lintian-75808db17caf8b960b351e3408e74142f4c85aac.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/init-d/init.d-lsb-headers')
-rw-r--r--t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/control.in90
-rw-r--r--t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-all.init22
-rw-r--r--t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-early-boot.init21
-rw-r--r--t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-length.init21
-rw-r--r--t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-local.init23
-rw-r--r--t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-missing.init19
-rw-r--r--t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-parsing.init21
-rw-r--r--t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-remote.init23
-rw-r--r--t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-virtual.init22
-rw-r--r--t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers.init23
-rw-r--r--t/recipes/checks/init-d/init.d-lsb-headers/build-spec/fill-values3
-rw-r--r--t/recipes/checks/init-d/init.d-lsb-headers/eval/desc2
-rw-r--r--t/recipes/checks/init-d/init.d-lsb-headers/eval/hints28
13 files changed, 318 insertions, 0 deletions
diff --git a/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/control.in b/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/control.in
new file mode 100644
index 0000000..07eac24
--- /dev/null
+++ b/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/control.in
@@ -0,0 +1,90 @@
+Source: [% $source %]
+Priority: optional
+Section: [% $section %]
+Maintainer: [% $author %]
+Standards-Version: [% $standards_version %]
+Build-Depends: [% $build_depends %]
+Rules-Requires-Root: no
+
+Package: [% $source %]
+Architecture: [% $package_architecture %]
+Pre-Depends: ${misc:Pre-Depends}
+Depends: ${shlibs:Depends}, ${misc:Depends}, lsb-base (>= 3.0-6)
+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.
+
+Package: [% $source %]-parsing
+Architecture: [% $package_architecture %]
+Pre-Depends: ${misc:Pre-Depends}
+Depends: ${shlibs:Depends}, ${misc:Depends}, lsb-base (>= 3.0-6)
+Description: [% $description %] -- headers parsing
+ This is a test package designed to exercise the parsing of init scripts
+ by Lintian. It is part of the Lintian test suite and may do very odd
+ things. It should not be installed like a regular package.
+
+Package: [% $source %]-remote
+Architecture: [% $package_architecture %]
+Pre-Depends: ${misc:Pre-Depends}
+Depends: ${shlibs:Depends}, ${misc:Depends}, lsb-base (>= 3.0-6)
+Description: [% $description %] -- using /usr files
+ This is a test package designed to exercise the checking of init scripts
+ by Lintian. It is part of the Lintian test suite and may do very odd
+ things. It should not be installed like a regular package.
+
+Package: [% $source %]-length
+Architecture: [% $package_architecture %]
+Pre-Depends: ${misc:Pre-Depends}
+Depends: ${shlibs:Depends}, ${misc:Depends}, lsb-base (>= 3.0-6)
+Description: [% $description %] -- breaking length assumptions
+ Test package designed to exercise the checking of init
+ scripts by Lintian. It is part of the Lintian test suite and may do
+ very odd things. It should not be installed like a regular package.
+
+Package: [% $source %]-local
+Architecture: [% $package_architecture %]
+Pre-Depends: ${misc:Pre-Depends}
+Depends: ${shlibs:Depends}, ${misc:Depends}, lsb-base (>= 3.0-6)
+Description: [% $description %] -- using /var files
+ This is another test package designed to exercise the checking of init
+ scripts by Lintian. It is part of the Lintian test suite and may do
+ very odd things. It should not be installed like a regular package.
+
+Package: [% $source %]-missing
+Architecture: [% $package_architecture %]
+Pre-Depends: ${misc:Pre-Depends}
+Depends: ${shlibs:Depends}, ${misc:Depends}, lsb-base (>= 3.0-6)
+Description: [% $description %] -- missing runlevels
+ This is yet another test package designed to exercise the checking of
+ init scripts by Lintian. It is part of the Lintian test suite and may
+ do very odd things. It should not be installed like a regular package.
+
+Package: [% $source %]-virtual
+Architecture: [% $package_architecture %]
+Pre-Depends: ${misc:Pre-Depends}
+Depends: ${shlibs:Depends}, ${misc:Depends}, lsb-base (>= 3.0-6)
+Description: [% $description %] -- virtual facilities
+ Test package to exercise the virtual facilities in init.d scripts
+ checks by lintian. It is part of the Lintian test suite and may
+ do very odd things. It should not be installed like a regular package.
+
+Package: [% $source %]-all
+Architecture: [% $package_architecture %]
+Pre-Depends: ${misc:Pre-Depends}
+Depends: ${shlibs:Depends}, ${misc:Depends}, lsb-base (>= 3.0-6)
+Description: [% $description %] -- all virtual facilities
+ Test package designed to exercise the checking of virtual all facilities
+ in init.d scripts checks by lintian.
+ It is part of the Lintian test suite and may
+ do very odd things. It should not be installed like a regular package.
+
+Package: [% $source %]-early-boot
+Architecture: [% $package_architecture %]
+Pre-Depends: ${misc:Pre-Depends}
+Depends: ${shlibs:Depends}, ${misc:Depends}, lsb-base (>= 3.0-6)
+Description: [% $description %] -- false positive
+ This is yet another test package designed to exercise the checking of
+ init scripts by Lintian. It is part of the Lintian test suite and may
+ do very odd things. It should not be installed like a regular
+ package.
diff --git a/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-all.init b/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-all.init
new file mode 100644
index 0000000..c9097f0
--- /dev/null
+++ b/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-all.init
@@ -0,0 +1,22 @@
+#!/bin/sh
+
+set -e
+
+### BEGIN INIT INFO
+# Provides: init.d-lsb-headers-all
+# Required-Start: $all
+# Should-Start: $all
+# Required-Stop: $all
+# Default-Start: 2 3 4 5
+# Default-Stop:
+# Short-Description: Test script for all virtual facility
+# Description: The short description pretty much covers it : test $all virtual facility
+### END INIT INFO
+
+. /lib/lsb/init-functions
+
+case "$1" in
+ start|stop|force-reload|restart|status|*)
+ echo hello world
+ ;;
+esac
diff --git a/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-early-boot.init b/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-early-boot.init
new file mode 100644
index 0000000..dcfa1c1
--- /dev/null
+++ b/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-early-boot.init
@@ -0,0 +1,21 @@
+#!/bin/sh
+
+set -e
+
+### BEGIN INIT INFO
+# Provides: init.d-lsb-headers-early-boot
+# Required-Start:
+# Required-Stop:
+# Default-Start: S
+# Default-Stop: 0 6
+# Short-Description: Do nothing at all
+# Description: The short description pretty much covers it.
+### END INIT INFO
+
+. /lib/lsb/init-functions
+
+case "$1" in
+ start|stop|force-reload|restart|status|*)
+ echo hello world
+ ;;
+esac
diff --git a/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-length.init b/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-length.init
new file mode 100644
index 0000000..e450395
--- /dev/null
+++ b/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-length.init
@@ -0,0 +1,21 @@
+#!/bin/sh
+
+set -e
+
+### BEGIN INIT INFO
+# Provides: init.d-lsb-headers-length
+# Required-Start:
+# Required-Stop:
+# Default-Start:
+# Default-Stop: 0 1 2 6
+# Short-Description: Do nothing at all
+# Description: The short description pretty much covers it.
+### END INIT INFO
+
+. /lib/lsb/init-functions
+
+case "$1" in
+ start|stop|force-reload|restart|status|*)
+ echo hello world!
+ ;;
+esac
diff --git a/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-local.init b/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-local.init
new file mode 100644
index 0000000..2f7049b
--- /dev/null
+++ b/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-local.init
@@ -0,0 +1,23 @@
+#!/bin/sh
+
+set -e
+
+### BEGIN INIT INFO
+# Provides: init.d-lsb-headers-local
+# Required-Start:
+# Required-Stop: $remote_fs
+# Default-Start: 2 3 4 5
+# Default-Stop: 0 1 6
+# Short-Description: Do nothing at all
+# Description: The short description pretty much covers it.
+### END INIT INFO
+
+exec >/var/log/foo.log
+
+. /lib/lsb/init-functions
+
+case "$1" in
+ start|stop|force-reload|restart|status|*)
+ echo hello world!
+ ;;
+esac
diff --git a/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-missing.init b/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-missing.init
new file mode 100644
index 0000000..4e60e54
--- /dev/null
+++ b/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-missing.init
@@ -0,0 +1,19 @@
+#!/bin/sh
+
+set -e
+
+### BEGIN INIT INFO
+# Provides: init.d-lsb-headers-missing
+# Required-Start:
+# Required-Stop:
+# Default-Start: 2 3 5
+# Default-Stop: 0 6
+### END INIT INFO
+
+. /lib/lsb/init-functions
+
+case "$1" in
+ start|stop|force-reload|restart|status|*)
+ echo hello world
+ ;;
+esac
diff --git a/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-parsing.init b/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-parsing.init
new file mode 100644
index 0000000..188e1f1
--- /dev/null
+++ b/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-parsing.init
@@ -0,0 +1,21 @@
+#!/bin/sh
+
+set -e
+
+### BEGIN INIT INFO
+# Provides: init.d-lsb-headers-parsing
+# Required-Start: $local_fs
+# Required-Stop:$local_fs
+# Default-Start: 0
+# Default-Stop: 0
+# Short-Description: Do nothing at all
+# Description: The short description pretty much covers it.
+### END INIT INFO
+
+. /lib/lsb/init-functions
+
+case "$1" in
+ start|stop|force-reload|restart|status|*)
+ echo hello world!
+ ;;
+esac
diff --git a/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-remote.init b/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-remote.init
new file mode 100644
index 0000000..c0a131c
--- /dev/null
+++ b/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-remote.init
@@ -0,0 +1,23 @@
+#!/bin/sh
+
+set -e
+
+### BEGIN INIT INFO
+# Provides: init.d-lsb-headers-remote
+# Required-Start: $local_fs
+# Required-Stop:
+# Should-Stop: $remote_fs
+# Default-Start: 2 3 4 5
+# Default-Stop:
+# Short-Description: Do nothing at all
+# Description: The short description pretty much covers it.
+### END INIT INFO
+
+. /lib/lsb/init-functions
+. /usr/share/foo/lib.sh
+
+case "$1" in
+ start|stop|force-reload|restart|status|*)
+ echo hello world!
+ ;;
+esac
diff --git a/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-virtual.init b/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-virtual.init
new file mode 100644
index 0000000..ac98ae9
--- /dev/null
+++ b/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers-virtual.init
@@ -0,0 +1,22 @@
+#!/bin/sh
+
+set -e
+
+### BEGIN INIT INFO
+# Provides: init.d-lsb-headers-virtual
+# Required-Start: $local_fs $something_that_doesnt_exist
+# Should-Start: $something_we_might_not_ship
+# Required-Stop: $all
+# Default-Start: 2 3 4 5
+# Default-Stop:
+# Short-Description: Just a test script
+# Description: The short description pretty much covers it.
+### END INIT INFO
+
+. /lib/lsb/init-functions
+
+case "$1" in
+ start|stop|force-reload|restart|status|*)
+ echo hello world
+ ;;
+esac
diff --git a/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers.init b/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers.init
new file mode 100644
index 0000000..847885c
--- /dev/null
+++ b/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/debian/init.d-lsb-headers.init
@@ -0,0 +1,23 @@
+#!/bin/sh
+
+set -e
+
+### BEGIN INIT INFO
+# Provides: nothing $bad_facility
+# Required-Start: mountall networking sysklogd
+# Should-Start: portmap
+# Required-Stop: mountnfs
+# Default-Start: 0 6 X
+# Default-Stop: S Y 0 6
+# Short-Description: Do nothing at all
+# Short-Description: Do nothing at all
+# Description: The short description pretty much covers it.
+### END INIT INFO
+
+. /lib/lsb/init-functions
+
+case "$1" in
+ start|stop|force-reload|restart|status|*)
+ echo hello world!
+ ;;
+esac
diff --git a/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/fill-values b/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/fill-values
new file mode 100644
index 0000000..0923808
--- /dev/null
+++ b/t/recipes/checks/init-d/init.d-lsb-headers/build-spec/fill-values
@@ -0,0 +1,3 @@
+Skeleton: upload-native
+Testname: init.d-lsb-headers
+Description: Test tags related to init script LSB headers
diff --git a/t/recipes/checks/init-d/init.d-lsb-headers/eval/desc b/t/recipes/checks/init-d/init.d-lsb-headers/eval/desc
new file mode 100644
index 0000000..9581842
--- /dev/null
+++ b/t/recipes/checks/init-d/init.d-lsb-headers/eval/desc
@@ -0,0 +1,2 @@
+Testname: init.d-lsb-headers
+Check: init-d
diff --git a/t/recipes/checks/init-d/init.d-lsb-headers/eval/hints b/t/recipes/checks/init-d/init.d-lsb-headers/eval/hints
new file mode 100644
index 0000000..8cfce94
--- /dev/null
+++ b/t/recipes/checks/init-d/init.d-lsb-headers/eval/hints
@@ -0,0 +1,28 @@
+init.d-lsb-headers-virtual (binary): init.d-script-depends-on-unknown-virtual-facility $something_that_doesnt_exist [etc/init.d/init.d-lsb-headers-virtual]
+init.d-lsb-headers-virtual (binary): init.d-script-depends-on-all-virtual-facility required-stop [etc/init.d/init.d-lsb-headers-virtual]
+init.d-lsb-headers-parsing (binary): init.d-script-starts-in-stop-runlevel 0 [etc/init.d/init.d-lsb-headers-parsing]
+init.d-lsb-headers-parsing (binary): init.d-script-possible-missing-stop 1 6 [etc/init.d/init.d-lsb-headers-parsing]
+init.d-lsb-headers-parsing (binary): init.d-script-has-conflicting-start-stop 0 [etc/init.d/init.d-lsb-headers-parsing]
+init.d-lsb-headers-missing (binary): init.d-script-possible-missing-stop 1 [etc/init.d/init.d-lsb-headers-missing]
+init.d-lsb-headers-missing (binary): init.d-script-missing-start 4 [etc/init.d/init.d-lsb-headers-missing]
+init.d-lsb-headers-missing (binary): init.d-script-missing-lsb-short-description [etc/init.d/init.d-lsb-headers-missing]
+init.d-lsb-headers-local (binary): init.d-script-missing-dependency-on-local_fs required-start [etc/init.d/init.d-lsb-headers-local]
+init.d-lsb-headers-all (binary): init.d-script-depends-on-all-virtual-facility should-start [etc/init.d/init.d-lsb-headers-all]
+init.d-lsb-headers-all (binary): init.d-script-depends-on-all-virtual-facility required-stop [etc/init.d/init.d-lsb-headers-all]
+init.d-lsb-headers-all (binary): init.d-script-depends-on-all-virtual-facility required-start [etc/init.d/init.d-lsb-headers-all]
+init.d-lsb-headers (binary): non-virtual-facility-in-initd-script sysklogd -> $syslog [etc/init.d/init.d-lsb-headers]
+init.d-lsb-headers (binary): non-virtual-facility-in-initd-script portmap -> $portmap [etc/init.d/init.d-lsb-headers]
+init.d-lsb-headers (binary): non-virtual-facility-in-initd-script networking -> $network [etc/init.d/init.d-lsb-headers]
+init.d-lsb-headers (binary): non-virtual-facility-in-initd-script mountnfs -> $remote_fs [etc/init.d/init.d-lsb-headers]
+init.d-lsb-headers (binary): non-virtual-facility-in-initd-script mountall -> $local_fs [etc/init.d/init.d-lsb-headers]
+init.d-lsb-headers (binary): init.d-script-starts-in-stop-runlevel 6 [etc/init.d/init.d-lsb-headers]
+init.d-lsb-headers (binary): init.d-script-starts-in-stop-runlevel 0 [etc/init.d/init.d-lsb-headers]
+init.d-lsb-headers (binary): init.d-script-provides-virtual-facility $bad_facility [etc/init.d/init.d-lsb-headers]
+init.d-lsb-headers (binary): init.d-script-possible-missing-stop 1 [etc/init.d/init.d-lsb-headers]
+init.d-lsb-headers (binary): init.d-script-has-duplicate-lsb-keyword short-description [etc/init.d/init.d-lsb-headers:13]
+init.d-lsb-headers (binary): init.d-script-has-conflicting-start-stop 6 [etc/init.d/init.d-lsb-headers]
+init.d-lsb-headers (binary): init.d-script-has-conflicting-start-stop 0 [etc/init.d/init.d-lsb-headers]
+init.d-lsb-headers (binary): init.d-script-has-bad-stop-runlevel Y [etc/init.d/init.d-lsb-headers]
+init.d-lsb-headers (binary): init.d-script-has-bad-start-runlevel X [etc/init.d/init.d-lsb-headers]
+init.d-lsb-headers (binary): init.d-script-does-not-provide-itself [etc/init.d/init.d-lsb-headers]
+init.d-lsb-headers (binary): init-d-script-stops-in-s-runlevel [etc/init.d/init.d-lsb-headers]