Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/aspnetwebstack.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source')
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Blocks.vbhtml46
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/CodeBlock.vbhtml3
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/CodeBlockAtEOF.vbhtml3
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ConditionalAttributes.vbhtml12
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/DesignTime.vbhtml21
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/EmptyExplicitExpression.vbhtml3
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/EmptyImplicitExpression.vbhtml3
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/EmptyImplicitExpressionInCode.vbhtml3
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ExplicitExpression.vbhtml1
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ExplicitExpressionAtEOF.vbhtml3
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ExpressionsInCode.vbhtml16
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/FunctionsBlock.vbhtml12
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Helpers.vbhtml11
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/HelpersMissingCloseParen.vbhtml8
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/HelpersMissingName.vbhtml1
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/HelpersMissingOpenParen.vbhtml8
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ImplicitExpression.vbhtml5
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ImplicitExpressionAtEOF.vbhtml3
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Imports.vbhtml6
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Inherits.vbhtml1
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Instrumented.vbhtml53
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/LayoutDirective.vbhtml1
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/MarkupInCodeBlock.vbhtml5
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/NestedCodeBlocks.vbhtml4
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/NestedHelpers.vbhtml10
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/NoLinePragmas.vbhtml45
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Options.vbhtml4
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ParserError.vbhtml3
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/RazorComments.vbhtml12
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ResolveUrl.vbhtml20
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Sections.vbhtml13
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Templates.vbhtml36
-rw-r--r--test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/UnfinishedExpressionInCode.vbhtml3
33 files changed, 378 insertions, 0 deletions
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Blocks.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Blocks.vbhtml
new file mode 100644
index 00000000..e2e02a69
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Blocks.vbhtml
@@ -0,0 +1,46 @@
+@Code
+ Dim i as Integer = 1
+End Code
+
+@While i <= 10
+ @<p>Hello from VB.Net, #@(i)</p>
+ i += 1
+End While
+
+@If i = 11 Then
+ @<p>We wrote 10 lines!</p>
+End If
+
+@Do
+ @<p>Hello again: @i</p>
+ i -= 1
+Loop While i > 0
+
+@Select Case i
+ Case 11
+ @<p>No really, we wrote 10 lines!</p>
+ Case Else
+ @<p>We wrote a bunch more lines too!</p>
+End Select
+
+@For j as Integer = 1 to 10 Step 2
+ @<p>Hello again from VB.Net, #@(j)</p>
+Next j
+
+@Try
+ @<p>That time, we wrote 5 lines!</p>
+Catch ex as Exception
+ @<p>Oh no! An error occurred: @(ex.Message)</p>
+End Try
+
+@With i
+ @<p>i is now @(.ToString())</p>
+End With
+
+@SyncLock New Object()
+ @<p>This block is locked, for your security!</p>
+End SyncLock
+
+@Using New System.IO.MemoryStream()
+ @<p>Some random memory stream will be disposed after rendering this block</p>
+End Using \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/CodeBlock.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/CodeBlock.vbhtml
new file mode 100644
index 00000000..c710eaf1
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/CodeBlock.vbhtml
@@ -0,0 +1,3 @@
+@Code
+ Test()
+End Code \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/CodeBlockAtEOF.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/CodeBlockAtEOF.vbhtml
new file mode 100644
index 00000000..011d09a1
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/CodeBlockAtEOF.vbhtml
@@ -0,0 +1,3 @@
+This is markup
+
+@Code \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ConditionalAttributes.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ConditionalAttributes.vbhtml
new file mode 100644
index 00000000..2e49d75f
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ConditionalAttributes.vbhtml
@@ -0,0 +1,12 @@
+@Code
+ Dim ch = True
+ Dim cls = "bar"
+ @<a href="Foo" />
+ @<p class="@cls" />
+ @<p class="foo @cls" />
+ @<p class="@cls foo" />
+ @<input type="checkbox" checked="@ch" />
+ @<input type="checkbox" checked="foo @ch" />
+ @<p class="@If cls IsNot Nothing Then @cls End If" />
+ @<a href="~/Foo" />
+End Code \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/DesignTime.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/DesignTime.vbhtml
new file mode 100644
index 00000000..cfd33e71
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/DesignTime.vbhtml
@@ -0,0 +1,21 @@
+<div>
+ @For i = 1 to 10
+@<p>This is item #@i</p>
+ Next
+</div>
+
+<p>
+@(Foo(Bar.Baz))
+@Foo(@@<p>Bar @baz Biz</p>)
+</p>
+
+@Section Footer
+ <p>Foo</p>
+ @bar
+End Section
+
+@Helper Foo()
+ If True Then
+ @<p>Foo</p>
+ End If
+End Helper \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/EmptyExplicitExpression.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/EmptyExplicitExpression.vbhtml
new file mode 100644
index 00000000..6790c7eb
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/EmptyExplicitExpression.vbhtml
@@ -0,0 +1,3 @@
+This is markup
+
+@() \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/EmptyImplicitExpression.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/EmptyImplicitExpression.vbhtml
new file mode 100644
index 00000000..021306da
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/EmptyImplicitExpression.vbhtml
@@ -0,0 +1,3 @@
+This is markup
+
+@! \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/EmptyImplicitExpressionInCode.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/EmptyImplicitExpressionInCode.vbhtml
new file mode 100644
index 00000000..deb98d53
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/EmptyImplicitExpressionInCode.vbhtml
@@ -0,0 +1,3 @@
+@Code
+ @
+End Code \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ExplicitExpression.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ExplicitExpression.vbhtml
new file mode 100644
index 00000000..b65eee56
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ExplicitExpression.vbhtml
@@ -0,0 +1 @@
+@(Foo(Bar.Baz)) \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ExplicitExpressionAtEOF.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ExplicitExpressionAtEOF.vbhtml
new file mode 100644
index 00000000..a0fdfc9a
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ExplicitExpressionAtEOF.vbhtml
@@ -0,0 +1,3 @@
+This is markup
+
+@( \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ExpressionsInCode.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ExpressionsInCode.vbhtml
new file mode 100644
index 00000000..3416ee9a
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ExpressionsInCode.vbhtml
@@ -0,0 +1,16 @@
+@Code
+ Dim foo As Object = Nothing
+ Dim bar as String = "Foo"
+End Code
+
+@If foo IsNot Nothing Then
+ @foo
+Else
+ @<p>Foo is Null!</p>
+End If
+
+<p>
+@If Not String.IsNullOrEmpty(bar) Then
+ @(bar.Replace("F", "B"))
+End If
+</p> \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/FunctionsBlock.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/FunctionsBlock.vbhtml
new file mode 100644
index 00000000..bcb78211
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/FunctionsBlock.vbhtml
@@ -0,0 +1,12 @@
+@Functions
+
+End Functions
+
+@Functions
+ Private _rand as New Random()
+ Private Function RandomInt() as Integer
+ Return _rand.Next()
+ End Function
+End Functions
+
+Here's a random number: @RandomInt() \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Helpers.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Helpers.vbhtml
new file mode 100644
index 00000000..6fead0cc
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Helpers.vbhtml
@@ -0,0 +1,11 @@
+@Helper Bold(s as String)
+ s = s.ToUpper()
+ @<strong>@s</strong>
+End Helper
+
+@Helper Italic(s as String)
+ s = s.ToUpper()
+ @<em>@s</em>
+End Helper
+
+@Bold("Hello") \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/HelpersMissingCloseParen.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/HelpersMissingCloseParen.vbhtml
new file mode 100644
index 00000000..d81d24b2
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/HelpersMissingCloseParen.vbhtml
@@ -0,0 +1,8 @@
+@Helper Bold(s as String)
+ s = s.ToUpper()
+ @<strong>@s</strong>
+End Helper
+
+@Helper Italic(s as String
+
+@Bold("Hello") \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/HelpersMissingName.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/HelpersMissingName.vbhtml
new file mode 100644
index 00000000..36ec5a7e
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/HelpersMissingName.vbhtml
@@ -0,0 +1 @@
+@Helper \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/HelpersMissingOpenParen.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/HelpersMissingOpenParen.vbhtml
new file mode 100644
index 00000000..145bda68
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/HelpersMissingOpenParen.vbhtml
@@ -0,0 +1,8 @@
+@Helper Bold(s as String)
+ s = s.ToUpper()
+ @<strong>@s</strong>
+End Helper
+
+@Helper Italic
+
+@Bold("Hello") \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ImplicitExpression.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ImplicitExpression.vbhtml
new file mode 100644
index 00000000..fb6f5281
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ImplicitExpression.vbhtml
@@ -0,0 +1,5 @@
+@For i = 1 To 10
+ @<p>This is item #@i</p>
+Next
+
+@SyntaxSampleHelpers.CodeForLink(Me) \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ImplicitExpressionAtEOF.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ImplicitExpressionAtEOF.vbhtml
new file mode 100644
index 00000000..365d20e0
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ImplicitExpressionAtEOF.vbhtml
@@ -0,0 +1,3 @@
+This is markup
+
+@ \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Imports.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Imports.vbhtml
new file mode 100644
index 00000000..da3f0ec1
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Imports.vbhtml
@@ -0,0 +1,6 @@
+@Imports System.IO
+@Imports Foo = System.Text.Encoding
+@Imports System
+
+<p>Path's full type name is @GetType(Path).FullName</p>
+<p>Foo's actual full type name is @GetType(Foo).FullName</p> \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Inherits.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Inherits.vbhtml
new file mode 100644
index 00000000..cc0a2d2a
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Inherits.vbhtml
@@ -0,0 +1 @@
+@Inherits System.Web.WebPages.WebPage
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Instrumented.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Instrumented.vbhtml
new file mode 100644
index 00000000..510aae4b
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Instrumented.vbhtml
@@ -0,0 +1,53 @@
+@Helper Strong(s As String)
+ @<strong>@s</strong>
+End Helper
+
+@Code
+ Dim i As Integer = 1
+ Dim foo = @@<p>Foo</p>
+ @:Hello, World!
+ @<p>Hello, World!</p>
+End Code
+
+@While i <= 10
+ @<p>Hello from VB.Net, #@(i)</p>
+ i += 1
+End While
+
+@If i = 11 Then
+ @<p>We wrote 10 lines!</p>
+End If
+
+@Do
+ @<p>Hello again: @i</p>
+ i -= 1
+Loop While i > 0
+
+@Select Case i
+ Case 11
+ @<p>No really, we wrote 10 lines!</p>
+ Case Else
+ @<p>We wrote a bunch more lines too!</p>
+End Select
+
+@For j as Integer = 1 to 10 Step 2
+ @<p>Hello again from VB.Net, #@(j)</p>
+Next j
+
+@Try
+ @<p>That time, we wrote 5 lines!</p>
+Catch ex as Exception
+ @<p>Oh no! An error occurred: @(ex.Message)</p>
+End Try
+
+@With i
+ @<p>i is now @(.ToString())</p>
+End With
+
+@SyncLock New Object()
+ @<p>This block is locked, for your security!</p>
+End SyncLock
+
+@Using New System.IO.MemoryStream()
+ @<p>Some random memory stream will be disposed after rendering this block</p>
+End Using \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/LayoutDirective.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/LayoutDirective.vbhtml
new file mode 100644
index 00000000..58904f11
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/LayoutDirective.vbhtml
@@ -0,0 +1 @@
+@Layout ~/Foo/Bar/Baz \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/MarkupInCodeBlock.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/MarkupInCodeBlock.vbhtml
new file mode 100644
index 00000000..83289134
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/MarkupInCodeBlock.vbhtml
@@ -0,0 +1,5 @@
+@Code
+ For i = 1 To 10
+ @<p>Hello from VB.Net, #@(i.ToString())</p>
+ Next i
+End Code
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/NestedCodeBlocks.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/NestedCodeBlocks.vbhtml
new file mode 100644
index 00000000..83f518ac
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/NestedCodeBlocks.vbhtml
@@ -0,0 +1,4 @@
+@If True Then
+ @If True Then
+ End If
+End If \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/NestedHelpers.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/NestedHelpers.vbhtml
new file mode 100644
index 00000000..4c52502b
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/NestedHelpers.vbhtml
@@ -0,0 +1,10 @@
+@Helper Italic(s As String)
+ s = s.ToUpper()
+ @Helper Bold(s As String)
+ s = s.ToUpper()
+ @<strong>@s</strong>
+ End Helper
+ @<em>@Bold(s)</em>
+End Helper
+
+@Italic("Hello") \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/NoLinePragmas.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/NoLinePragmas.vbhtml
new file mode 100644
index 00000000..4e9df788
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/NoLinePragmas.vbhtml
@@ -0,0 +1,45 @@
+@Code
+ Dim i as Integer = 1
+End Code
+
+@While i <= 10
+ @<p>Hello from VB.Net, #@(i)</p>
+ i += 1
+ 'End While
+End While
+
+@If i = 11 Then
+ @<p>We wrote 10 lines!</p>
+ Dim s = "End If"
+End If
+
+@Select Case i
+ Case 11
+ @<p>No really, we wrote 10 lines!</p>
+ Case Else
+ @<p>Actually, we didn't...</p>
+End Select
+
+@For j as Integer = 1 to 10 Step 2
+ @<p>Hello again from VB.Net, #@(j)</p>
+Next
+
+@Try
+ @<p>That time, we wrote 5 lines!</p>
+Catch ex as Exception
+ @<p>Oh no! An error occurred: @(ex.Message)</p>
+End Try
+
+@With i
+ @<p>i is now @(.ToString())</p>
+End With
+
+@SyncLock New Object()
+ @<p>This block is locked, for your security!</p>
+End SyncLock
+
+@Using New System.IO.MemoryStream()
+ @<p>Some random memory stream will be disposed after rendering this block</p>
+End Using
+
+@SyntaxSampleHelpers.CodeForLink(Me) \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Options.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Options.vbhtml
new file mode 100644
index 00000000..0cd49aa3
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Options.vbhtml
@@ -0,0 +1,4 @@
+@Option Strict On
+@Option Explicit Off
+
+Hello, World! \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ParserError.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ParserError.vbhtml
new file mode 100644
index 00000000..2d2e4227
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ParserError.vbhtml
@@ -0,0 +1,3 @@
+@Code
+Foo
+'End Code \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/RazorComments.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/RazorComments.vbhtml
new file mode 100644
index 00000000..7c638d63
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/RazorComments.vbhtml
@@ -0,0 +1,12 @@
+@*This is not going to be rendered*@
+<p>This should @* not *@ be shown</p>
+
+@Code
+ @* Throw new Exception("Oh no!") *@
+End Code
+
+@Code Dim bar As String = "@* bar *@" End Code
+<p>But this should show the comment syntax: @bar</p>
+<p>So should this: @@* bar *@@</p>
+
+@(a@**@b) \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ResolveUrl.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ResolveUrl.vbhtml
new file mode 100644
index 00000000..dc20f644
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/ResolveUrl.vbhtml
@@ -0,0 +1,20 @@
+<a href="~/Foo">Foo</a>
+<a href="~/Products/@product.id">@product.Name</a>
+<a href="~/Products/@product.id/Detail">Details</a>
+<a href="~/A+Really(Crazy),Url.Is:This/@product.id/Detail">Crazy Url!</a>
+
+@Code
+ @<text>
+ <a href="~/Foo">Foo</a>
+ <a href="~/Products/@product.id">@product.Name</a>
+ <a href="~/Products/@product.id/Detail">Details</a>
+ <a href="~/A+Really(Crazy),Url.Is:This/@product.id/Detail">Crazy Url!</a>
+ </text>
+End Code
+
+@Section Foo
+ <a href="~/Foo">Foo</a>
+ <a href="~/Products/@product.id">@product.Name</a>
+ <a href="~/Products/@product.id/Detail">Details</a>
+ <a href="~/A+Really(Crazy),Url.Is:This/@product.id/Detail">Crazy Url!</a>
+End Section \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Sections.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Sections.vbhtml
new file mode 100644
index 00000000..ad05f5cd
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Sections.vbhtml
@@ -0,0 +1,13 @@
+@Code
+ Layout = "_SectionTestLayout.vbhtml"
+End Code
+
+<div>This is in the Body>
+
+@Section Section2
+ <div>This is in Section 2</div>
+End Section
+
+@Section Section1
+ <div>This is in Section 1</div>
+End Section \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Templates.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Templates.vbhtml
new file mode 100644
index 00000000..80e17703
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/Templates.vbhtml
@@ -0,0 +1,36 @@
+@Imports System.Web.Helpers
+
+@Functions
+ Public Function Repeat(times As Integer, template As Func(Of Integer, object)) As HelperResult
+ Return New HelperResult(Sub(writer)
+ For i = 0 to times
+ DirectCast(template(i), HelperResult).WriteTo(writer)
+ Next i
+ End Sub)
+ End Function
+End Functions
+
+@Code
+ Dim foo As Func(Of Object, Object) = @<text>This works @item!</text>
+ @foo("too")
+End Code
+
+<ul>
+@(Repeat(10, @@<li>Item #@item</li>))
+</ul>
+
+<p>
+@Repeat(10,
+ @@: This is line#@item of markup<br/>
+)
+</p>
+
+<ul>
+ @Repeat(10, @@<li>
+ Item #@item
+ @Code Dim parent = item End Code
+ <ul>
+ <li>Child Items... ?</li>
+ </ul>
+ </li>)
+</ul> \ No newline at end of file
diff --git a/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/UnfinishedExpressionInCode.vbhtml b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/UnfinishedExpressionInCode.vbhtml
new file mode 100644
index 00000000..4b4acb3b
--- /dev/null
+++ b/test/System.Web.Razor.Test/TestFiles/CodeGenerator/VB/Source/UnfinishedExpressionInCode.vbhtml
@@ -0,0 +1,3 @@
+@Code
+@DateTime.
+End Code \ No newline at end of file