Merge pull request #697 from kaysoky/ContextSwitchFail

Revert context change for UnsentMessageWorker
Partial refactoring of the EntityServletTestHelper to repeat less code.
Finished up changes to entity servlet test helper.
Another chunk of refactoring.
Finished up refactor of non-entity servlet helper.
Fix up too-specific exception handling of affected tests
+ Rename misspelled method
Fixing up mistakes made in refactoring.
+ Changing the expected exceptions in some tests to match refactored exceptions
+ Removed now redundant Servlet Exception class