public async Task TestWebServerRender() { var result = await _rs.RenderAsync(new RenderRequest() { Template = new Template() { Content = "Hello world", Recipe = Recipe.Html, Engine = Engine.Handlebars } }); new StreamReader(result.Content).ReadToEnd().ShouldBe("Hello world"); }
public async Task TestDataSerializeWithCamelCase() { var result = await _rs.RenderAsync(new RenderRequest() { Template = new Template() { Content = "{{helloWorld}}", Recipe = Recipe.Html, Engine = Engine.Handlebars }, Data = new { HelloWorld = "foo" } }); new StreamReader(result.Content).ReadToEnd().ShouldBe("foo"); }