Allowed boto to register hvm instances

This PR applies #1726 from @amiato as well as fixes PEP8 issues and adds unit tests.

@toastdriven please review.