One thing not on the manual page, and not covered here yet, is that the '/usr/sbin/dhcpd -t' command uses the return value to indicate whether the configuration is correct or not.
If there are no errors, it will return zero. if there are syntax errors it will return non zero (1 for the test I did)
So you can use something like:
/usr/sbin/dhcpd -t
if [ $? -ne 0 ]; then
echo "Configuration has errors, aborting"
fi
/bin/systemctl restart isc-dhcp-server
To check if changes made to the configuration are valid before trying to restart the server with the new version.
Unfortunately I don't think there is any option to just display the errors. It would be possible to use a text parsing tool (awk, python etc) to remove the header lines (for the version I have, everything up to a line beginning with "For info"), and trailer lines (for the version I have, everything after a line saying "Configuration file errors encountered -- exiting") which would leave just the syntax error and location