Hello community,
I thought I have a fairly easy problem but I somehow always struggle with the Kibana visualizations.
What I have is an index with test case execution records. Where each document in the index has a filed for the software version, a test case name and a verdict.
I now wanted to draw a heatmap with the version on the x-axis and the test case name on the y axis. Each position in the grid should then be colored depending on their verdict like this. If all verdicts for a given version and test case name combination are passed it should be green. If one or more verdicts are failed it should be red. Possible other verdicts could be inconclusive and yellow or similar...
The time of the test case execution would not be considered for the aggregation.
It then should look something like this:
Is this possible with the standard visualization or only with e.g. Vega?
Thanks a lot,
Fabian
Hi @Fabian_Sturm
It sounds to be something feasible with Lens.
Do you have any document example?
Sure,
the documents would look like this:
{
"test_case": "test case 1",
"version": "1.0.3",
"verdict": "passed"
},
{
"test_case": "test case 2",
"version": "1.0.3",
"verdict": "passed"
},
{
"test_case": "test case 1",
"version": "1.0.4",
"verdict": "failed"
},
{
"test_case": "test case 2",
"version": "1.0.4",
"verdict": "passed"
},
{
"test_case": "test case 2",
"version": "1.0.4",
"verdict": "failed"
}
As you can see the structure is pretty simple. I need the version on the x-axis and the different test case names on the y axis.
An additional issue is that there can be more than one document for a given test case and version combination. E.g. in this example the last test case is repeated with a different outcome. Therefore, I need the aggregation that calculates the color depending on how many passed and failed are for each combination.
Hope that helps to explain the original problem statement
E.g. in this example the last test case is repeated with a different outcome. Therefore, I need the aggregation that calculates the color depending on how many passed and failed are for each combination.
Sorry, to clarify here, you mean that for test case 2
you need only the last one correct?
Thanks for asking. The logic would be more like this for each test_case version combination:
if one or more verdicts are failed -> red
if all verdicts are passed -> green
for no verdicts -> grey or no value