This is just a failing test demonstrating the behavior I'd like to see. There is currently some inconsistency between sendmail and smtp transports:
sendmail transport: Envelope sender can be specified on a per-message basis with the :sender key.
smtp transport: Envelope sender can be specified with :sender key in server param to send-message. The :sender key in msg is used as the From address, but it's not possible to set SMTP envelope sender separately from the From address.
Ideally, the :sender key could be used to set the SMTP envelope sender for both the smtp and sendmail transports. To make this happen, we will need to create a new Session instance for each message with a :sender key.
Work in progress
This is just a failing test demonstrating the behavior I'd like to see. There is currently some inconsistency between sendmail and smtp transports:
Ideally, the :sender key could be used to set the SMTP envelope sender for both the smtp and sendmail transports. To make this happen, we will need to create a new Session instance for each message with a :sender key.
What do you think?