Class CoverageQualityGate
java.lang.Object
hudson.model.AbstractDescribableImpl<io.jenkins.plugins.util.QualityGate>
io.jenkins.plugins.util.QualityGate
io.jenkins.plugins.coverage.metrics.steps.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.- Author:
- Johannes Walter
- See Also:
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class io.jenkins.plugins.util.QualityGate
io.jenkins.plugins.util.QualityGate.QualityGateCriticality, io.jenkins.plugins.util.QualityGate.QualityGateDescriptor
-
Constructor Summary
ConstructorsConstructorDescriptionCoverageQualityGate
(edu.hm.hafner.coverage.Metric metric) Creates a new instance ofCoverageQualityGate
. -
Method Summary
Modifier and TypeMethodDescriptionedu.hm.hafner.coverage.Metric
getName()
Returns a human-readable name of the quality gate.final void
setBaseline
(Baseline baseline) Sets the baseline that will be used for the quality gate evaluation.Methods inherited from class io.jenkins.plugins.util.QualityGate
getCriticality, getIntegerThreshold, getStatus, getThreshold, setCriticality, setIntegerThreshold, setThreshold, toString
Methods inherited from class hudson.model.AbstractDescribableImpl
getDescriptor
-
Constructor Details
-
CoverageQualityGate
@DataBoundConstructor public CoverageQualityGate(edu.hm.hafner.coverage.Metric metric) Creates a new instance ofCoverageQualityGate
.- Parameters:
metric
- the metric to compare
-
-
Method Details
-
setBaseline
Sets the baseline that will be used for the quality gate evaluation.- Parameters:
baseline
- the baseline to use
-
getName
Returns a human-readable name of the quality gate.- Specified by:
getName
in classio.jenkins.plugins.util.QualityGate
- Returns:
- a human-readable name
-
getMetric
public edu.hm.hafner.coverage.Metric getMetric() -
getBaseline
-