Can you add a unit test for this exception?