added handling for hex decoding exceptions

Also, switched some of the test request creation to use functions, rather than defs. Noticed that :body streams were being mutated, causing tests to fail if executed multiple times in the same repl session.