13 changed files with 136 additions and 25 deletions
@ -0,0 +1,17 @@
@@ -0,0 +1,17 @@
|
||||
// Copyright (c) AlphaSierraPapa for the SharpDevelop Team (for details please see \doc\copyright.txt)
|
||||
// This code is distributed under the GNU LGPL (for details please see \doc\license.txt)
|
||||
|
||||
using System; |
||||
|
||||
namespace ICSharpCode.AspNet.Mvc.Folding |
||||
{ |
||||
public class VisualBasicRazorLanguageBinding : HtmlLanguageBinding |
||||
{ |
||||
public VisualBasicRazorLanguageBinding() |
||||
: base( |
||||
new TextEditorWithParseInformationFoldingFactory(), |
||||
new RazorFoldGeneratorFactory(".vbhtml")) |
||||
{ |
||||
} |
||||
} |
||||
} |
||||
@ -0,0 +1,36 @@
@@ -0,0 +1,36 @@
|
||||
// Copyright (c) AlphaSierraPapa for the SharpDevelop Team (for details please see \doc\copyright.txt)
|
||||
// This code is distributed under the GNU LGPL (for details please see \doc\license.txt)
|
||||
|
||||
using System; |
||||
using ICSharpCode.AspNet.Mvc.Folding; |
||||
using NUnit.Framework; |
||||
|
||||
namespace AspNet.Mvc.Tests.Folding |
||||
{ |
||||
[TestFixture] |
||||
public class RazorHtmlSpansTests |
||||
{ |
||||
RazorHtmlSpans htmlSpans; |
||||
|
||||
void CreateHtmlSpans(string fileExtension) |
||||
{ |
||||
htmlSpans = new RazorHtmlSpans(String.Empty, fileExtension); |
||||
} |
||||
|
||||
[Test] |
||||
public void CodeLanguageName_CSharpRazorFileExtension_ReturnsCSharp() |
||||
{ |
||||
CreateHtmlSpans(".cshtml"); |
||||
|
||||
Assert.AreEqual("csharp", htmlSpans.CodeLanguageName); |
||||
} |
||||
|
||||
[Test] |
||||
public void CodeLanguageName_VisualBasicRazorFileExtension_ReturnsVisualBasicRazorFileExtensionWithoutDot() |
||||
{ |
||||
CreateHtmlSpans(".vbhtml"); |
||||
|
||||
Assert.AreEqual("vb", htmlSpans.CodeLanguageName); |
||||
} |
||||
} |
||||
} |
||||
Loading…
Reference in new issue