Cleanup test code, improve error messages.
Cleanup test code, improve error messages.

mburggraf/otrs,MBRG/otrs,mburggraf/otrs,MBRG/otrs,xhoy/otrs,MBRG/otrs,rudy500/otrs,xhoy/otrs,s7design/otrs,rudy500/otrs,s7design/otrs,MBRG/otrs,rudy500/otrs,rudy500/otrs,s7design/otrs,xhoy/otrs,s7design/otrs,mburggraf/otrs,MBRG/otrs,xhoy/otrs,s7design/otrs,mburggraf/otrs,rudy500/otrs,xhoy/otrs,mburggraf/otrs