Adds one or more error badges to the current Pipeline build. Warning badges text messages with an icon and an optional clickable hyperlink. Warning badges are often used to provide a visual indicator of additional status information about a Pipeline build. Warning badges added by addWarningBadge are displayed in the build history of the Pipeline job.

Example: Badge with text

The following example adds a warning badge with the text, "This is alarming":

addWarningBadge text: 'This is alarming'

Example: Badge with text and link

The following example adds a warning badge with the text, "This is alarming" and a link:

addWarningBadge text: 'This is alarming', link: 'https://issues.jenkins.io/browse/JENKINS-59646'