Modify the error case using assert_throws.