Safe Haskell | None |
---|---|
Language | Haskell2010 |
Test.Sandwich.Formatters.Slack
Synopsis
- data SlackFormatter
- newtype SlackConfig = SlackConfig {}
- defaultSlackFormatter :: SlackFormatter
- slackFormatterSlackConfig :: SlackFormatter -> SlackConfig
- slackFormatterChannel :: SlackFormatter -> String
- slackFormatterTopMessage :: SlackFormatter -> Maybe String
- slackFormatterMaxFailures :: SlackFormatter -> Maybe Int
- slackFormatterMaxFailureReasonLines :: SlackFormatter -> Maybe Int
- slackFormatterMaxCallStackLines :: SlackFormatter -> Maybe Int
- slackFormatterVisibilityThreshold :: SlackFormatter -> Maybe Int
- slackFormatterMaxMessageSize :: SlackFormatter -> Maybe Int64
- data SlackFormatterShowCallStacks
Documentation
data SlackFormatter Source #
Instances
Formatter SlackFormatter Source # | |
Defined in Test.Sandwich.Formatters.Slack Methods formatterName :: SlackFormatter -> String # runFormatter :: (MonadIO m, MonadLogger m, MonadUnliftIO m, MonadCatch m) => SlackFormatter -> [RunNode BaseContext] -> Maybe (CommandLineOptions ()) -> BaseContext -> m () # finalizeFormatter :: (MonadIO m, MonadLogger m, MonadCatch m) => SlackFormatter -> [RunNode BaseContext] -> BaseContext -> m () # |
newtype SlackConfig Source #
Configuration options needed to connect to the Slack API
Constructors
SlackConfig | |
Fields
|
Instances
Show SlackConfig Source # | |
Defined in Test.Sandwich.Formatters.Internal.Types Methods showsPrec :: Int -> SlackConfig -> ShowS # show :: SlackConfig -> String # showList :: [SlackConfig] -> ShowS # |
slackFormatterSlackConfig :: SlackFormatter -> SlackConfig Source #
Slack credentials
slackFormatterChannel :: SlackFormatter -> String Source #
Slack channel on which to create the progress bar.
slackFormatterTopMessage :: SlackFormatter -> Maybe String Source #
Message to put above the progress bar. For example, the name of the test suite and a link to the run in the CI system.
slackFormatterMaxFailures :: SlackFormatter -> Maybe Int Source #
Maximum number of failures to include in a message. If too many are included, it's possible to hit Slack's request limit of 8KB, which causes the message to fail to update. Defaults to 30.
slackFormatterMaxFailureReasonLines :: SlackFormatter -> Maybe Int Source #
Maximum number of lines to devote to showing the failure reason underneath a failure. Set to 'Just 0' to disable showing failure reasons.
slackFormatterMaxCallStackLines :: SlackFormatter -> Maybe Int Source #
Maximum number of lines to devote to showing the call stack underneath a failure. Set to 'Just 0' to disable showing call stacks.
slackFormatterVisibilityThreshold :: SlackFormatter -> Maybe Int Source #
If present, filter the headings on failures to only include nodes whose visibility threshold is less than or equal to the value.
slackFormatterMaxMessageSize :: SlackFormatter -> Maybe Int64 Source #
If present, make sure the messages we transmit to Slack default don't exceed this number
of bytes. When a message does exceed it (probably because there are a ton of failures),
start dropping blocks from the end of the message until the size is small enough.
Making use of slackFormatterMaxFailures
, slackFormatterMaxFailureReasonLines
, and
slackFormatterMaxCallStackLines
is a good way to avoid hitting the limit.
data SlackFormatterShowCallStacks Source #
Constructors
SlackFormatterNoCallStacks | Don't include callstacks in failure messages |
SlackFormatterTopNCallStackFrames Int | Include the top N stack frames |
SlackFormatterFullCallStack | Include the full callstack |