help needed to add built specific statistics
I've added some console output within my build such as
##teamcity[buildStatisticValue key='ProjectName:CoveredTableCount' value='60']
##teamcity[buildStatisticValue key='ProjectName:UncoveredTableCount' value='94']
I can see these in the actual build log
and I've followed this documentation page:
http://confluence.jetbrains.net/display/TCD5/Custom+Chart
leading me to add a <graph/> element to main-config.xml:
<graph title="Arbirtrary graph title" defaultFilters="" hideFilters="showFailed" seriesTitle="Arbitrary series title">
<valueType key="ProjectName:CoveredTableCount" title="Covered table count" buildTypeId="6" />
<valueType key="ProjectName:UncoveredTableCount" title="Uncovered table count" buildTypeId="6" />
</graph>
after several trials, I didn't succeed, the particular build never showed a "statistics" tab.
I also tried to move these statistics at project level but only succeeded to display an empty graph (values do not seem to be picked up).
Any idea what I'm missing to get the build statistics to show up?
Thanks for your help!
Please sign in to leave a comment.
Hello,
I suspect that you should replace buildTypeId="6" with buildTypeId="bt6" . Could you please try it?
Best regards,
KIR
Hello Kirill,
I tried to change the ids with the one matching the url, same as you gave: bt6 and the statistic is not showing in the build configuration statistic screen.
Any other idea about what might be wrong?
Thanks for your help.
Hello,

Could you please clarify how do you log the messages? Can you provide your build log?
I've just created a configuration with copy-paste from your data (just fixed buildTypeIds) and it works for me.
The graph from 2 builds looks like the following:
These messages are logged through Console.WriteLine (.NET) in a NUnit test dll, run via an msbuild configuration setting
here is an excerpt of the full build log output:
What you shown is exactly what I'm looking for, I hope I'm not so far :)