improved code

* made code fragments more clear to understand
added tests for ParallelCurl

* added tests and improved code