Class CoverageQualityGate

  • All Implemented Interfaces:
    Describable<io.jenkins.plugins.util.QualityGate>, Serializable

    public class CoverageQualityGate
    extends io.jenkins.plugins.util.QualityGate
    Defines a quality gate based on a specific threshold of code coverage in the current build. After a build has been finished, a set of quality gates will be evaluated and the overall quality gate status will be reported in Jenkins UI.
    Johannes Walter
    See Also:
    Serialized Form
    • Constructor Detail

      • CoverageQualityGate

        public CoverageQualityGate​(double threshold,
                                   Baseline type,
                                   io.jenkins.plugins.util.QualityGate.QualityGateCriticality criticality)
        Creates a new instance of CoverageQualityGate.
        threshold - minimum or maximum value that triggers this quality gate
    • Method Detail

      • setType

        public final void setType​(Baseline type)
        Sets the baseline that will be used for the quality gate evaluation.
        type - the baseline to use
      • getName

        public String getName()
        Returns a human-readable name of the quality gate.
        Specified by:
        getName in class io.jenkins.plugins.util.QualityGate
        a human-readable name
      • getMetric

        public Metric getMetric()