send_via_mailgate's return should act like send_via_mailgate_and_http

a7a0e02c switched to call RT::Interface::Email::Gateway rather than
using bin/rt-mailgate; however, it returned 0/1/-75 for
failure/success/tmpfail instead of the exit code ($?).  Since all
callsites shifted the return code by 8 and accepted 0 as "success," all
calls succeeded.

Fake a $?-like return code from send_via_mailgate; left-shifted 1 for
failure, left-shifted -75 for temporary failure, and 0 for success.

Fixes I#19156.
Merge branch '4.2/test-mailgate-return' into 4.2-trunk