fixed unittest
fixed error message
some cleanups
Merge pull request #1 from mzeibig/master

fixed unittest