Skip to content

Commit a9bc184

Browse files
author
Jake Ginnivan
committed
Fixes issue #47
1 parent a16cbe6 commit a9bc184

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed
Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
namespace TestStack.ConventionTests.Reporting
22
{
33
using System;
4+
using TestStack.ConventionTests.ConventionData;
45

56
public class TypeDataFormatter : IReportDataFormatter
67
{
@@ -11,16 +12,15 @@ public bool CanFormat(object data)
1112

1213
public string FormatString(object data)
1314
{
14-
return ((Type)data).FullName;
15+
return ((Type)data).ToTypeNameString();
1516
}
1617

1718
public string FormatHtml(object data)
1819
{
1920
var type = ((Type)data);
20-
var ns = type.Namespace;
21-
if (ns == null)
22-
return type.Name;
23-
return string.Format("{0}.<strong>{1}</strong>", ns, type.Name);
21+
var oldValue = string.Format("{0}.", type.Namespace);
22+
var newValue = string.Format("{0}.<strong>", type.Namespace);
23+
return string.Format("{0}</strong>", FormatString(data).Replace(oldValue, newValue));
2424
}
2525
}
2626
}

0 commit comments

Comments
 (0)