mirror of
https://github.com/wxWidgets/wxWidgets.git
synced 2026-09-26 18:18:26 +08:00
Add a script and CI action for tests/allheaders.h
Check that all headers are either #included or mentioned in tests/allheaders.h.
This commit is contained in:
committed by
Vadim Zeitlin
parent
01ecc95cea
commit
f88a0a933d
@@ -101,3 +101,15 @@ jobs:
|
||||
echo "::error ::Please use C++11 equivalents of the deprecated macros in the new code."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
check-allheaders:
|
||||
runs-on: ubuntu-20.04
|
||||
name: Check All Headers In allheaders.h
|
||||
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Check that all headers are listed in tests/allheaders.h
|
||||
run: |
|
||||
./misc/scripts/check_allheaders.sh
|
||||
|
||||
Executable
+15
@@ -0,0 +1,15 @@
|
||||
#!/bin/bash
|
||||
|
||||
cd $(dirname "$0")/../..
|
||||
|
||||
rc=0
|
||||
|
||||
for h in include/wx/*.h ; do
|
||||
header=wx/$(basename "$h")
|
||||
if ! grep -q "$header" tests/allheaders.h ; then
|
||||
echo "ERROR - <$header> not present in tests/allheaders.h"
|
||||
rc=$((rc+1))
|
||||
fi
|
||||
done
|
||||
|
||||
exit $rc
|
||||
Reference in New Issue
Block a user