public CreateCodeGenerator ( string className, string rootNamespaceName, string sourceFileName, System.Web.Razor.RazorEngineHost host ) : System.Web.Razor.Generator.RazorCodeGenerator | ||
className | string | |
rootNamespaceName | string | |
sourceFileName | string | |
host | System.Web.Razor.RazorEngineHost | |
Результат | System.Web.Razor.Generator.RazorCodeGenerator |
public void Must_honor_exception_parameter(bool throwExceptionOnParserError) { var language = new VisualBasicCodeLanguage(throwExceptionOnParserError); var host = MockRepository.GenerateMock<RazorEngineHost>(); RazorCodeGenerator generator = language.CreateCodeGenerator("ClassName", "RootNamespace", "Template.vbhtml", host); Assert.That(((VisualBasicCodeGenerator)generator).ThrowExceptionOnParserError, Is.EqualTo(throwExceptionOnParserError)); }
public void Must_create_visualbasiccodegenerator() { var language = new VisualBasicCodeLanguage(); var host = MockRepository.GenerateMock<RazorEngineHost>(); RazorCodeGenerator generator = language.CreateCodeGenerator("ClassName", "RootNamespace", "Template.vbhtml", host); Assert.That(generator, Is.InstanceOf<VisualBasicCodeGenerator>()); }