Fixed tests by mocking http

Fixes #22