smtptest
package v2.23.0
Go to latest Published: Jun 3, 2025 License:AGPL-3.0
Opens a new window with list of versions in this module.
Latest LatestThis package is not in the latest version of its module.
Opens a new window with license information.
Imports:10 Opens a new window with list of imports.
Imported by:0 Opens a new window with list of known importers.
Details
Validgo.mod file
The Go module system was introduced in Go 1.11 and is the official dependency management solution for Go.
Redistributable license
Redistributable licenses place minimal restrictions on how software can be used, modified, and redistributed.
Tagged version
Modules with tagged versions give importers more predictable builds.
Stable version
When a project reaches major version v1 it is considered stable.
- Learn more about best practices
Repository
Links
Documentation¶
Index¶
- func CreateMockSMTPServer(be *Backend, useTLS bool) (*smtp.Server, net.Listener, error)
- func PingClient(listen net.Listener, useTLS bool, startTLS bool) (*smtp.Client, error)
- type Backend
- type Config
- type Message
- type Session
- func (s *Session) Auth(mech string) (sasl.Server, error)
- func (s *Session) AuthMechanisms() []string
- func (s *Session) Data(r io.Reader) error
- func (*Session) Logout() error
- func (s *Session) Mail(from string, _ *smtp.MailOptions) error
- func (s *Session) Rcpt(to string, _ *smtp.RcptOptions) error
- func (*Session) Reset()
Constants¶
This section is empty.
Variables¶
This section is empty.
Functions¶
funcCreateMockSMTPServer¶
nolint:revive // Yes, useTLS is a control flag.
Types¶
typeBackend¶
type Backend struct {// contains filtered or unexported fields}
funcNewBackend¶
func (*Backend)LastMessage¶
LastMessage returns a copy of the last message received by thebackend.
func (*Backend)NewSession¶
NewSession is called after client greeting (EHLO, HELO).
Click to show internal directories.
Click to hide internal directories.