add new rules and tests
Merge pull request #352 from mimmi20/issue-349

Fixes #349
Merge pull request #351 from mimmi20/master

Fixes #317