FailedTestCount – No data in builds
Hi All,
I am trying to set up a Statistics page for a Project that will display number of failed tests for some of the Build configurations in that project. Idea is to have a single page reporting failed tests over the week for all build configurations that do have tests in the project (like a summary for Management team).
To do that, I’ve followed Displaying Custom Chart in TeamCity Web UI ,edited <TeamCity Data Directory>/config/projects/<ProjectID>/pluginData/plugin-settings.xml file and added entries to display statistics:
<?xml version="1.0" encoding="UTF-8"?>
<settings>
<custom-graphs> <!-- This tag is required only in plugin-settings.xml -->
<graph title="Failed tests" hideFilters="showFailed" seriesTitle="Test name">
<valueType key="FailedTestCount" title="Day Zero Tests => CI R2" buildTypeId="DayZeroTests"/>
</graph>
</custom-graphs>
</settings>
The graph is coming up on the Project > Statistics page, but it is showing No data in builds message. If I open up the build overview page of the DayZeroTests (which is in this project) I can see many results over the past week with Tests failed: 2, passed: 5.
Why is it not displayed in the Project statistics then? Is FailedTestCount variable available in TeamCity Enterprise 8.0 (build 27402) that we use or only from version 8.1?
I would prefer to make it working in the current version, rather then upgrading to 8.1 if possible.
Thanks,
TRK
Please sign in to leave a comment.
Hi,
FailedTestCount variable is available in TeamCity 8.0.
By default TeamCity does not show failed builds. There are two options:
1. exclude hideFilters="showFailed" parameter, then you will be able to check "Show failed" option on graph
2. use defaultFilters="showFailed" hideFilters="showFailed", then failed builds will always be shown at graph
To clarify: before TeamCity 8.1, there were no option to see all statistic values reported by the build on the Build Results|Parameters|Reported statistic values tab. But all default variables are available.
Thank you Alina, that was very helpful. I've got it all showing nicely now. Here is end result if
anyone else have same issue:
Cheers,
TRK