Fix broken test that relied on message format for exception