add rule and test
update from the master branch
Merge pull request #277 from mimmi20/issue-269

Fixes #269