Add a few more tests and some documentation to error uses