templates.js.steps-chart.js Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of cucumber-reporting Show documentation
Show all versions of cucumber-reporting Show documentation
Provides pretty html reports for Cucumber (Behaviour-Driven Development). It works by generating html from the
cucumber json report formatter. So can be used anywhere a json report is generated. Current use is in the
cucumber jenkins plugin and a maven mojo to generate the same report from mvn command line when running locally.
$(document).ready(function() {
var chartData = {
datasets: [{
data: [
$report_summary.getPassedSteps(),
$report_summary.getFailedSteps(),
$report_summary.getSkippedSteps(),
$report_summary.getPendingSteps(),
$report_summary.getUndefinedSteps(),
$report_summary.getMissingSteps()
],
backgroundColor: [
"#00B000",
"#FF3030",
"#88AAFF",
"#F5F28F",
"#F5B975",
"#FAB3E9"
],
}],
labels: [
"Passed",
"Failed",
"Skipped",
"Pending",
"Undefined",
"Missing"
]
};
var ctx = document.getElementById("steps-chart");
window.myBar = new Chart(ctx, {
type: 'doughnut',
data: chartData,
options: {
title: {
display: true,
fontSize: 20,
text: 'Steps'
},
responsive: true,
legend: {
display: false
}
}
});
}); © 2015 - 2025 Weber Informatics LLC | Privacy Policy