From c5efd282371d5b199d2d96c13ea3334a42161dfb Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 28 Apr 2024 06:42:34 +0200 Subject: Adding debian version 1.7. Signed-off-by: Daniel Baumann --- debian/tests/shellcheck | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100755 debian/tests/shellcheck (limited to 'debian/tests/shellcheck') diff --git a/debian/tests/shellcheck b/debian/tests/shellcheck new file mode 100755 index 0000000..e85e422 --- /dev/null +++ b/debian/tests/shellcheck @@ -0,0 +1,36 @@ +#!/bin/sh + +set -eu + +. "$(dirname "$0")/shared-functions.sh" + +testname="$(basename "$0")" +pkgname="libnss-test-$testname" + +nss_lines=" +passwd last mynss +group before=files mynss +shadow after=files mynss [!SUCCESS=notfound] +gshadow first mynss [NOTFOUND=return] +hosts remove-only mynss +protocols after=db mynss skip-if-present=files +" + +echo "Set up and build test package..." +cd "$AUTOPKGTEST_TMP" +mkdir "$pkgname" +cd "$pkgname" +setup_pkg "$pkgname" "$testname" +build_pkg "$pkgname" "1" "$nss_lines" + +echo "Extract maintscripts..." +cd "$AUTOPKGTEST_TMP" +dpkg-deb -e "${pkgname}_1_all.deb" control + +echo "Check for errors and warnings..." +cd control/ +test -s postinst +test -s postrm +shellcheck postinst +shellcheck postrm +echo "OK" -- cgit v1.2.3