add test
Merge pull request #307 from mimmi20/issue-305

Fixes #305