Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MessageRenderer ¶
type MessageRenderer struct {
// contains filtered or unexported fields
}
MessageRenderer renders Slack message
func NewMessageRenderer ¶
func NewMessageRenderer() (*MessageRenderer, error)
NewMessageRenderer returns new instance of MessageRenderer
func (*MessageRenderer) RenderSlackMessage ¶
func (s *MessageRenderer) RenderSlackMessage(in RenderSlackMessageInput) (string, string, string, error)
RenderSlackMessage returns header and body summary of given tests
type RenderSlackMessageInput ¶
type RenderSlackMessageInput struct { Details string Header string ClusterName string LogID string }
RenderSlackMessageInput holds input parameters required to render test summary
type SlackClient ¶
type SlackClient struct {
// contains filtered or unexported fields
}
SlackClient sends message to slack channel
func NewSlackClient ¶
func NewSlackClient(cfg SlackClientConfig) *SlackClient
NewSlackClient returns new instance of SlackClient
func (*SlackClient) Send ¶
func (c *SlackClient) Send(header, body, footer, color string) error
Send sends message with given content to slack channel
type SlackClientConfig ¶
SlackClientConfig holds configuration for slack client
type SlackNotifier ¶
type SlackNotifier struct {
// contains filtered or unexported fields
}
SlackNotifier sends notification messages to Slack channel.
func New ¶
func New(clusterName string, slack slackClient, testRenderer msgRenderer) *SlackNotifier
New returns new instance of SlackNotifier
func (*SlackNotifier) Notify ¶
func (s *SlackNotifier) Notify(id, header, details string) error
Notify sends notification message to Slack channel
Click to show internal directories.
Click to hide internal directories.