Compare commits

...

2 Commits

Author SHA1 Message Date
cclecle
886a22bef2 add missing java lib in groovy 2023-03-23 22:23:57 +00:00
cclecle
e9355471ba cast float to strings 2023-03-23 22:19:48 +00:00

9
Jenkinsfile vendored
View File

@@ -11,6 +11,7 @@ import static javax.xml.xpath.XPathConstants.*
import javax.xml.xpath.*
import groovy.xml.DOMBuilder
import groovy.xml.dom.DOMCategory
import java.math.RoundingMode
// configurable settings:
// use to send email if workflow problem
@@ -440,11 +441,13 @@ pipeline {
println GetCoverageValue_branch_rate(coverage_report_path)
println GetCoverageValue_branches_complexity(coverage_report_path)
full_rate = (GetCoverageValue_line_rate(coverage_report_path) + GetCoverageValue_branch_rate(coverage_report_path)) / 2
badge_coverage.setStatus(full_rate)
full_rate = (GetCoverageValue_line_rate(coverage_report_path) + GetCoverageValue_branch_rate(coverage_report_path)) / 2
sz_full_rate =Float.toString(full_rate.setScale(2, RoundingMode.HALF_EVEN))
badge_coverage.setStatus(sz_full_rate)
complexity = GetCoverageValue_branches_complexity(coverage_report_path)
badge_complexity.setStatus(complexity)
sz_complexity =Float.toString(complexity.setScale(2, RoundingMode.HALF_EVEN))
badge_complexity.setStatus(sz_complexity)
}
}
}