refactor(test): correctly load hosts.json

* * *

This commit was sponsored by The Hoodie Firm.
You can hire The Hoodie Firm:
http://go.hood.ie/thehoodiefirm
test: split tests and write spec in cjs pattern

* * *

This commit was sponsored by The Hoodie Firm.
You can hire The Hoodie Firm:
http://go.hood.ie/thehoodiefirm