I don't see you using the $BAD_* below; are we missing some tests ?  Or are these variables (and bad.sh) superfluous ?