Tests for dnssec, minor tweaks for constants and handle closing