public void Output_field_html_with_field_configuration_values() { var form = _h.BeginChameleonForm(); var html = form.FieldFor(m => m.Decimal).AddClass("a-class").ToHtmlString(); HtmlApprovals.VerifyHtml(html); }
public void Construct_form_via_extension_method() { var t = new DefaultFormTemplate(); var f2 = _h.BeginChameleonForm(Action, Method, new HtmlAttributes(), Enctype); Assert.That(f2, Is.Not.Null); _h.ViewContext.Writer.Received().Write(Arg.Is <Nancy.ViewEngines.Razor.IHtmlString>(h => h.ToHtmlString() == t.BeginForm(Action, Method, _htmlAttributes, Enctype).ToHtmlString())); }