Limit number of parallel tests (Fixes #176)

This introduces the option --max_parallel to limit the number of parallel tasks. See #176
First shot, comments welcome.