org.conqat.engine.sourcecode.coverage.CoverageUnitContainer Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of teamscale-commons Show documentation
Show all versions of teamscale-commons Show documentation
Provides common DTOs for Teamscale
The newest version!
package org.conqat.engine.sourcecode.coverage;
/**
* Contains a coverage unit. This is a piece a coverage that is associated with a specific test
* execution or execution unit.
*/
public class CoverageUnitContainer {
/**
* Whether the coverage unit was contained in a report that had the partial flag set to true.
*/
private boolean partOfPartialReport;
/** The coverage of the coverage unit. */
private final MultiFileRangeCoverageInfo coverageInfo = new MultiFileRangeCoverageInfo();
public boolean isPartOfPartialReport() {
return partOfPartialReport;
}
public void setPartOfPartialReport(boolean partOfPartialReport) {
this.partOfPartialReport = partOfPartialReport;
}
/** @see #coverageInfo */
public MultiFileRangeCoverageInfo getCoverageInfo() {
return coverageInfo;
}
/**
* Describes the execution nature of a coverage unit when it is referenced multiple times. i.e. in
* JUnit code in a @BeforeAll block would be only executed once even when multiple tests in a class
* exist.
*/
public enum ECoverageUnitType {
/**
* The test step is executed just once if multiple tests referencing this coverage unit are
* executed.
*/
EXECUTED_ONCE,
/**
* The test step is always executed if a test or execution unit that references this coverage unit
* is executed.
*/
ALWAYS_EXECUTED
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy