slack

package
v0.175.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 2, 2024 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Reporter

type Reporter struct {
	Channels       []string
	TestResults    []report.TestResult
	Framework      string
	Metadata       config.Metadata
	TestEnv        string
	RenderedResult string
	Config         config.Notifications
	Service        Service
	// contains filtered or unexported fields
}

Reporter represents reporter for slack

func (*Reporter) Add

func (r *Reporter) Add(t report.TestResult)

Add adds the TestResult to the reporter. TestResults added this way can then be rendered out by calling Render().

func (*Reporter) ArtifactRequirements

func (r *Reporter) ArtifactRequirements() []report.ArtifactType

ArtifactRequirements no need to implement

func (*Reporter) GetRenderedResult

func (r *Reporter) GetRenderedResult() string

GetRenderedResult returns rendered result.

func (*Reporter) Render

func (r *Reporter) Render()

Render renders the test results and sends message to the Slack.

func (*Reporter) Reset

func (r *Reporter) Reset()

Reset no need to implement

type Service

type Service interface {
	GetSlackToken(ctx context.Context) (string, error)
}

Service represents an interface for retrieving slack token.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL