Documentation
¶
Overview ¶
Package mailer implements common functionality for sending emails and for testing
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Renderer ¶
type Renderer struct {
// contains filtered or unexported fields
}
Renderer for easy template of TXT or HTML
func TemplateHTML ¶
TemplateHTML - create template render for html
type Service ¶
type Service struct {
SMTPHost string `config:"smtp_host" toml:"smtp_host"`
SMTPPort int `config:"smtp_port" toml:"smtp_port"`
SMTPUsername string `config:"smtp_username" toml:"smtp_username"`
SMTPPassword string `config:"smtp_password" toml:"smtp_password"`
SMTPSSL bool `config:"smtp_ssl" toml:"smtp_ssl"`
Dailer *mail.Dialer `config:"-" toml:"-"`
From string `config:"from" toml:"from"`
}
Service to send mail
func NewFakeServer ¶
NewFakeServer - to get mocked Service for mail-service
type TestingMail ¶
type TestingMail struct {
Header textproto.MIMEHeader
Body string
}
TestingMail a mail in format from test server
Click to show internal directories.
Click to hide internal directories.