fix unit test

had a problem with one of the unit tests after throwing an error when
 the url is not a url