Add tests for ssl checking
Misc imports cleanup and better doc message