@@ -25,7 +25,7 @@ public Task TestCompileAsync()
2525 public void TestCompileAndRun_HtmlLiteral ( )
2626 {
2727 RazorEngine razorEngine = new RazorEngine ( ) ;
28- RazorEngineCompiledTemplate template = razorEngine . Compile ( "<h1>Hello @Model.Name</h1>" ) ;
28+ IRazorEngineCompiledTemplate template = razorEngine . Compile ( "<h1>Hello @Model.Name</h1>" ) ;
2929
3030 string actual = template . Run ( new
3131 {
@@ -39,7 +39,7 @@ public void TestCompileAndRun_HtmlLiteral()
3939 public async Task TestCompileAndRun_HtmlLiteralAsync ( )
4040 {
4141 RazorEngine razorEngine = new RazorEngine ( ) ;
42- RazorEngineCompiledTemplate template = await razorEngine . CompileAsync ( "<h1>Hello @Model.Name</h1>" ) ;
42+ IRazorEngineCompiledTemplate template = await razorEngine . CompileAsync ( "<h1>Hello @Model.Name</h1>" ) ;
4343
4444 string actual = await template . RunAsync ( new
4545 {
@@ -53,7 +53,7 @@ public async Task TestCompileAndRun_HtmlLiteralAsync()
5353 public void TestCompileAndRun_InAttributeVariables ( )
5454 {
5555 RazorEngine razorEngine = new RazorEngine ( ) ;
56- RazorEngineCompiledTemplate template = razorEngine . Compile ( "<div class=\" circle\" style=\" background-color: hsla(@Model.Colour, 70%, 80%,1);\" >" ) ;
56+ IRazorEngineCompiledTemplate template = razorEngine . Compile ( "<div class=\" circle\" style=\" background-color: hsla(@Model.Colour, 70%, 80%,1);\" >" ) ;
5757
5858 string actual = template . Run ( new
5959 {
@@ -67,7 +67,7 @@ public void TestCompileAndRun_InAttributeVariables()
6767 public async Task TestCompileAndRun_InAttributeVariablesAsync ( )
6868 {
6969 RazorEngine razorEngine = new RazorEngine ( ) ;
70- RazorEngineCompiledTemplate template = await razorEngine . CompileAsync ( "<div class=\" circle\" style=\" background-color: hsla(@Model.Colour, 70%, 80%,1);\" >" ) ;
70+ IRazorEngineCompiledTemplate template = await razorEngine . CompileAsync ( "<div class=\" circle\" style=\" background-color: hsla(@Model.Colour, 70%, 80%,1);\" >" ) ;
7171
7272 string actual = await template . RunAsync ( new
7373 {
@@ -81,7 +81,7 @@ public async Task TestCompileAndRun_InAttributeVariablesAsync()
8181 public void TestCompileAndRun_HtmlAttribute ( )
8282 {
8383 RazorEngine razorEngine = new RazorEngine ( ) ;
84- RazorEngineCompiledTemplate template = razorEngine . Compile ( "<div title=\" @Model.Name\" >Hello</div>" ) ;
84+ IRazorEngineCompiledTemplate template = razorEngine . Compile ( "<div title=\" @Model.Name\" >Hello</div>" ) ;
8585
8686 string actual = template . Run ( new
8787 {
@@ -95,7 +95,7 @@ public void TestCompileAndRun_HtmlAttribute()
9595 public async Task TestCompileAndRun_HtmlAttributeAsync ( )
9696 {
9797 RazorEngine razorEngine = new RazorEngine ( ) ;
98- RazorEngineCompiledTemplate template = await razorEngine . CompileAsync ( "<div title=\" @Model.Name\" >Hello</div>" ) ;
98+ IRazorEngineCompiledTemplate template = await razorEngine . CompileAsync ( "<div title=\" @Model.Name\" >Hello</div>" ) ;
9999
100100 string actual = await template . RunAsync ( new
101101 {
@@ -109,7 +109,7 @@ public async Task TestCompileAndRun_HtmlAttributeAsync()
109109 public void TestCompileAndRun_DynamicModel_Plain ( )
110110 {
111111 RazorEngine razorEngine = new RazorEngine ( ) ;
112- RazorEngineCompiledTemplate template = razorEngine . Compile ( "Hello @Model.Name" ) ;
112+ IRazorEngineCompiledTemplate template = razorEngine . Compile ( "Hello @Model.Name" ) ;
113113
114114 string actual = template . Run ( new
115115 {
@@ -123,7 +123,7 @@ public void TestCompileAndRun_DynamicModel_Plain()
123123 public async Task TestCompileAndRun_DynamicModel_PlainAsync ( )
124124 {
125125 RazorEngine razorEngine = new RazorEngine ( ) ;
126- RazorEngineCompiledTemplate template = await razorEngine . CompileAsync ( "Hello @Model.Name" ) ;
126+ IRazorEngineCompiledTemplate template = await razorEngine . CompileAsync ( "Hello @Model.Name" ) ;
127127
128128 string actual = await template . RunAsync ( new
129129 {
@@ -339,7 +339,7 @@ void RecursionTest(int level)
339339 public void TestCompileAndRun_TypedModel1 ( )
340340 {
341341 RazorEngine razorEngine = new RazorEngine ( ) ;
342- RazorEngineCompiledTemplate < TestModel1 > template = razorEngine . Compile < TestModel1 > ( "Hello @A @B @(A + B) @C @Decorator(\" 777\" )" ) ;
342+ IRazorEngineCompiledTemplate < TestModel1 > template = razorEngine . Compile < TestModel1 > ( "Hello @A @B @(A + B) @C @Decorator(\" 777\" )" ) ;
343343
344344 string actual = template . Run ( instance =>
345345 {
@@ -355,7 +355,7 @@ public void TestCompileAndRun_TypedModel1()
355355 public async Task TestCompileAndRun_TypedModel1Async ( )
356356 {
357357 RazorEngine razorEngine = new RazorEngine ( ) ;
358- RazorEngineCompiledTemplate < TestModel1 > template = await razorEngine . CompileAsync < TestModel1 > ( "Hello @A @B @(A + B) @C @Decorator(\" 777\" )" ) ;
358+ IRazorEngineCompiledTemplate < TestModel1 > template = await razorEngine . CompileAsync < TestModel1 > ( "Hello @A @B @(A + B) @C @Decorator(\" 777\" )" ) ;
359359
360360 string actual = await template . RunAsync ( instance =>
361361 {
@@ -371,7 +371,7 @@ public async Task TestCompileAndRun_TypedModel1Async()
371371 public void TestCompileAndRun_TypedModel2 ( )
372372 {
373373 RazorEngine razorEngine = new RazorEngine ( ) ;
374- RazorEngineCompiledTemplate < TestModel2 > template = razorEngine . Compile < TestModel2 > ( "Hello @Model.Decorator(Model.C)" ) ;
374+ IRazorEngineCompiledTemplate < TestModel2 > template = razorEngine . Compile < TestModel2 > ( "Hello @Model.Decorator(Model.C)" ) ;
375375
376376 string actual = template . Run ( instance =>
377377 {
@@ -388,7 +388,7 @@ public void TestCompileAndRun_TypedModel2()
388388 public async Task TestCompileAndRun_TypedModel2Async ( )
389389 {
390390 RazorEngine razorEngine = new RazorEngine ( ) ;
391- RazorEngineCompiledTemplate < TestModel2 > template = await razorEngine . CompileAsync < TestModel2 > ( "Hello @Model.Decorator(Model.C)" ) ;
391+ IRazorEngineCompiledTemplate < TestModel2 > template = await razorEngine . CompileAsync < TestModel2 > ( "Hello @Model.Decorator(Model.C)" ) ;
392392
393393 string actual = await template . RunAsync ( instance =>
394394 {
@@ -405,7 +405,7 @@ public async Task TestCompileAndRun_TypedModel2Async()
405405 public void TestCompileAndRun_Linq ( )
406406 {
407407 RazorEngine razorEngine = new RazorEngine ( ) ;
408- RazorEngineCompiledTemplate < TestModel2 > template = razorEngine . Compile < TestModel2 > (
408+ IRazorEngineCompiledTemplate < TestModel2 > template = razorEngine . Compile < TestModel2 > (
409409@"
410410@foreach (var item in Model.Numbers.OrderByDescending(x => x))
411411{
@@ -432,7 +432,7 @@ public void TestCompileAndRun_Linq()
432432 public async Task TestCompileAndRun_LinqAsync ( )
433433 {
434434 RazorEngine razorEngine = new RazorEngine ( ) ;
435- RazorEngineCompiledTemplate < TestModel2 > template = await razorEngine . CompileAsync < TestModel2 > (
435+ IRazorEngineCompiledTemplate < TestModel2 > template = await razorEngine . CompileAsync < TestModel2 > (
436436@"
437437@foreach (var item in Model.Numbers.OrderByDescending(x => x))
438438{
0 commit comments