Modified tests to account for await accepting dots.

#45
This commit is contained in:
N. Taylor Mullen 2014-05-12 15:05:18 -07:00
parent d0541ad5b2
commit 9bd2fdecac
4 changed files with 47 additions and 16 deletions

View File

@ -109,12 +109,14 @@ namespace Microsoft.AspNet.Razor.Test.Generator
BuildLineMapping(391, 12, 66, 1066, 58, 18, 1),
BuildLineMapping(448, 13, 49, 1146, 64, 19, 5),
BuildLineMapping(578, 18, 42, 1225, 69, 15, 15),
BuildLineMapping(640, 19, 41, 1316, 74, 17, 22),
BuildLineMapping(711, 20, 42, 1409, 79, 12, 39),
BuildLineMapping(806, 21, 49, 1521, 85, 13, 1),
BuildLineMapping(811, 21, 54, 1600, 91, 18, 27),
BuildLineMapping(842, 21, 85, 1708, 96, 22, 1),
BuildLineMapping(902, 22, 52, 1788, 102, 19, 19)
BuildLineMapping(650, 19, 51, 1317, 74, 18, 19),
BuildLineMapping(716, 20, 41, 1412, 79, 17, 22),
BuildLineMapping(787, 21, 42, 1505, 84, 12, 39),
BuildLineMapping(884, 22, 51, 1619, 90, 15, 21),
BuildLineMapping(961, 23, 49, 1713, 96, 13, 1),
BuildLineMapping(966, 23, 54, 1792, 102, 18, 27),
BuildLineMapping(997, 23, 85, 1900, 107, 22, 1),
BuildLineMapping(1057, 24, 52, 1980, 113, 19, 19)
});
}

View File

@ -72,34 +72,45 @@ namespace TestOutput
#line default
#line hidden
#line 20 "Await.cshtml"
__o = await Foo("bob", true);
__o = await Foo.Bar(1, 2);
#line default
#line hidden
#line 21 "Await.cshtml"
__o = await Foo("bob", true);
#line default
#line hidden
#line 22 "Await.cshtml"
await Foo(something, hello: "world");
#line default
#line hidden
#line 22 "Await.cshtml"
#line 23 "Await.cshtml"
await Foo.Bar(1, 2)
#line default
#line hidden
#line 24 "Await.cshtml"
#line default
#line hidden
#line 22 "Await.cshtml"
#line 24 "Await.cshtml"
__o = await Foo(boolValue: false);
#line default
#line hidden
#line 22 "Await.cshtml"
#line 24 "Await.cshtml"
#line default
#line hidden
#line 23 "Await.cshtml"
#line 25 "Await.cshtml"
__o = await ("wrrronggg");
#line default

View File

@ -83,9 +83,18 @@ namespace TestOutput
#line hidden
);
WriteLiteral("</p>\r\n <p>Advanced Asynchronous Template: ");
WriteLiteral("</p>\r\n <p>Advanced Asynchronous Expression Extended: ");
Write(
#line 20 "Await.cshtml"
await Foo.Bar(1, 2)
#line default
#line hidden
);
WriteLiteral("</p>\r\n <p>Advanced Asynchronous Template: ");
Write(
#line 21 "Await.cshtml"
await Foo("bob", true)
#line default
@ -93,15 +102,22 @@ namespace TestOutput
);
WriteLiteral("</p>\r\n <p>Advanced Asynchronous Statement: ");
#line 21 "Await.cshtml"
#line 22 "Await.cshtml"
await Foo(something, hello: "world");
#line default
#line hidden
WriteLiteral("</p>\r\n <p>Advanced Asynchronous Statement Extended: ");
#line 23 "Await.cshtml"
await Foo.Bar(1, 2)
#line default
#line hidden
WriteLiteral("</p>\r\n <p>Advanced Asynchronous Statement Nested: <b>");
Write(
#line 22 "Await.cshtml"
#line 24 "Await.cshtml"
await Foo(boolValue: false)
#line default
@ -109,7 +125,7 @@ namespace TestOutput
);
WriteLiteral("</b> ");
#line 22 "Await.cshtml"
#line 24 "Await.cshtml"
#line default
@ -117,7 +133,7 @@ namespace TestOutput
WriteLiteral("</p>\r\n <p>Advanced Incomplete Asynchronous Statement: ");
Write(
#line 23 "Await.cshtml"
#line 25 "Await.cshtml"
await ("wrrronggg")
#line default

View File

@ -17,8 +17,10 @@
<section>
<h1>Advanced Asynchronous Expression Test</h1>
<p>Advanced Asynchronous Expression: @await Foo(1, 2)</p>
<p>Advanced Asynchronous Expression Extended: @await Foo.Bar(1, 2)</p>
<p>Advanced Asynchronous Template: @(await Foo("bob", true))</p>
<p>Advanced Asynchronous Statement: @{ await Foo(something, hello: "world"); }</p>
<p>Advanced Asynchronous Statement Extended: @{ await Foo.Bar(1, 2) }</p>
<p>Advanced Asynchronous Statement Nested: @{ <b>@await Foo(boolValue: false)</b> }</p>
<p>Advanced Incomplete Asynchronous Statement: @await ("wrrronggg")</p>
</section>