DarthFubuMVC/fubumvc — pull request #169 by ianbattersby (2011-10-25 22:25:22+00:00)
Title: Added generic UrlFor<> extension method to IUrlRegistry.

(nb: simple amendment to make sure I've got my Git workflow in order)

We use the UrlFor extension method quite a bit to generate Url's (for form action attributes/etc) but naturally adopt the inferred/generic approach opposed to explicit new'ing; for example:

<%= Urls.UrlFor(new HomeFilesModel()) %>

.. becomes ..

<%= Urls.UrlFor() %>

Have tried to implement the same pattern of tests as per other extension methods, hope you agree it's worthy and sufficient. As part of the submissions I've changed the HelloWorld Home.aspx to reflect usage of this new method.