refactors some test
Merge pull request #28 from folieadrien/improves-error-handling

refactors some test