Add tests for coverage that throws

Inspired by #177