garanti/shared/report
Types
The effect of a token used for semantic highligting.
pub type Effect {
Positive
Negative
Important
Name
Bold
Secondary
}
Constructors
-
PositivePositive outcomes of tests, etc.
-
NegativeNegative outcomes, such as test failures.
-
ImportantNot a failure, but something is not right.
-
NameImporant parts of a message, such as test or suite name.
-
BoldAdds additional emphasis to a piece of text
-
SecondarySupportive text, fully readable but dot not compete for attention.
The level of importance for the overall message (much like log level).
pub type Level {
Success
Error
Warning
Info
Debug
}
Constructors
-
Success -
Error -
Warning -
Info -
Debug
The different types of tokens that can be used to construct a message.
pub type Token {
Plain(text: String)
Enriched(text: String, effects: List(Effect))
Indent
Block(text: String)
NewLine
}
Constructors
-
Plain(text: String)Plain text string.
-
Enriched(text: String, effects: List(Effect))A string with optional effects. Not all effects can be combined (such as combining colors).
-
IndentIndent the output (if applicable).
-
Block(text: String)Separate the output from the adjacent text (if applicable).
-
NewLineMove the output to a new line if applicable.