Class CoverageQualityGate
java.lang.Object
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.MetricgetName()Returns a human-readable name of the quality gate.final voidsetBaseline(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, toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface hudson.model.Describable
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:
getNamein classio.jenkins.plugins.util.QualityGate- Returns:
- a human-readable name
-
getMetric
public edu.hm.hafner.coverage.Metric getMetric() -
getBaseline
-