DRY test suite by replacing dublicate tests with shared examples