Merge branch '871-add-a-ci-check-for-missing-prereq.sh-scripts' into 'master'

Add a CI check for missing prereq.sh scripts

Closes #871

See merge request isc-projects/bind9!1494
This commit is contained in:
Mark Andrews
2019-02-11 16:48:12 -05:00
3 changed files with 28 additions and 0 deletions

View File

@@ -154,6 +154,7 @@ stages:
misc:sid:amd64:
<<: *precheck_job
script:
- sh util/check-ans-prereq.sh
- sh util/checklibs.sh > checklibs.out
- sh util/tabify-changes < CHANGES > CHANGES.tmp
- diff -urNap CHANGES CHANGES.tmp

26
util/check-ans-prereq.sh Normal file
View File

@@ -0,0 +1,26 @@
#!/bin/sh
#
# Copyright (C) Internet Systems Consortium, Inc. ("ISC")
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
# See the COPYRIGHT file distributed with this work for additional
# information regarding copyright ownership.
status=0
for testscript in bin/tests/system/*/tests.sh; do
testdir="$(dirname "${testscript}")"
prereq="${testdir}/prereq.sh"
if [ -e "${prereq}" ] || [ -e "${prereq}.in" ]; then
continue
fi
if find "${testdir}" -type d -name "ans*" | grep -Eq "/ans[0-9]+$"; then
echo "missing ${prereq}"
status=1
fi
done
exit ${status}

View File

@@ -2585,6 +2585,7 @@
./util/COPYRIGHT.TOP X 2018,2019
./util/bindkeys.pl PERL 2009,2010,2011,2012,2014,2016,2017,2018,2019
./util/branchsync.sh SH 2013,2016,2018,2019
./util/check-ans-prereq.sh SH 2019
./util/check-categories.sh SH 2015,2016,2017,2018,2019
./util/check-changes PERL 2002,2004,2007,2012,2016,2018,2019
./util/check-cocci X 2018,2019