@@ -514,7 +514,7 @@ public void CustomSummary(IEnumerable<Assembly> assemblies, IEnumerable<RiskHots
514514 foreach ( var metric in riskHotspot . StatusMetrics )
515515 {
516516 this . javaScriptContent . Append ( " { " ) ;
517- this . javaScriptContent . AppendFormat ( "\" value\" : {0}," , metric . Metric . Value . HasValue ? metric . Metric . Value . Value . ToString ( CultureInfo . InvariantCulture ) : "null" ) ;
517+ this . javaScriptContent . AppendFormat ( "\" value\" : {0}," , metric . Metric . Value . HasValue ? metric . Metric . Value . Value . ToString ( "0.##" , CultureInfo . InvariantCulture ) : "null" ) ;
518518 this . javaScriptContent . AppendFormat ( " \" exceeded\" : {0}" , metric . Exceeded . ToString ( ) . ToLowerInvariant ( ) ) ;
519519 this . javaScriptContent . AppendLine ( " }," ) ;
520520 }
@@ -640,7 +640,7 @@ public void MetricsTable(Class @class)
640640 {
641641 this . reportTextWriter . Write (
642642 "<td>{0}{1}</td>" ,
643- metricValue . Value . HasValue ? metricValue . Value . Value . ToString ( CultureInfo . InvariantCulture ) : "-" ,
643+ metricValue . Value . HasValue ? metricValue . Value . Value . ToString ( "0.##" , CultureInfo . InvariantCulture ) : "-" ,
644644 metricValue . Value . HasValue && metricValue . MetricType == MetricType . CoveragePercentual ? "%" : string . Empty ) ;
645645 }
646646
@@ -695,7 +695,7 @@ public void MetricsTable(IEnumerable<MethodMetric> methodMetrics)
695695
696696 foreach ( var metricValue in methodMetric . Metrics . Select ( m => m . Value ) )
697697 {
698- this . reportTextWriter . Write ( "<td>{0}</td>" , metricValue . HasValue ? metricValue . Value . ToString ( CultureInfo . InvariantCulture ) : "-" ) ;
698+ this . reportTextWriter . Write ( "<td>{0}</td>" , metricValue . HasValue ? metricValue . Value . ToString ( "0.##" , CultureInfo . InvariantCulture ) : "-" ) ;
699699 }
700700
701701 this . reportTextWriter . WriteLine ( "</tr>" ) ;
@@ -953,7 +953,7 @@ public void RiskHotspots(IEnumerable<RiskHotspot> riskHotspots)
953953 this . reportTextWriter . WriteLine (
954954 "<td class=\" {0} right\" >{1}</td>" ,
955955 statusMetric . Exceeded ? "lightred" : "lightgreen" ,
956- statusMetric . Metric . Value . HasValue ? statusMetric . Metric . Value . Value . ToString ( CultureInfo . InvariantCulture ) : "-" ) ;
956+ statusMetric . Metric . Value . HasValue ? statusMetric . Metric . Value . Value . ToString ( "0.##" , CultureInfo . InvariantCulture ) : "-" ) ;
957957 }
958958
959959 this . reportTextWriter . WriteLine ( "</tr>" ) ;
0 commit comments