Converted Html.Link to return MvcHtmlString. Replaced unnecessary calls to <%= with <%: as a result of this change.

Added some unit tests for Html.Link.

--HG--
branch : dev
This commit is contained in:
Phil Haack
2010-06-09 23:06:36 -07:00
parent fa3c6a2854
commit 013638aca8
23 changed files with 97 additions and 28 deletions

View File

@@ -19,7 +19,7 @@
sbClass.Append("current ");
var classValue = sbClass.ToString().TrimEnd(); %>
<li<%=!string.IsNullOrEmpty(classValue) ? string.Format(" class=\"{0}\"", classValue) : "" %>><%=Html.Link(menuItem.Text, menuItem.Href) %></li><%
<li<%=!string.IsNullOrEmpty(classValue) ? string.Format(" class=\"{0}\"", classValue) : "" %>><%: Html.Link(menuItem.Text, menuItem.Href) %></li><%
++counter;
} %>
</ul>