Fix email test

Looks like text attachment content has to be specified as str, not bytes.