Add RazorTemplate
This commit is contained in:
parent
3a041176e9
commit
9ccf6501ef
|
|
@ -0,0 +1,37 @@
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.IO;
|
||||||
|
using System.Linq;
|
||||||
|
|
||||||
|
namespace AspNetCoreSdkTests.Templates
|
||||||
|
{
|
||||||
|
public class RazorTemplate : WebTemplate
|
||||||
|
{
|
||||||
|
public override string Name => "razor";
|
||||||
|
|
||||||
|
public override IEnumerable<string> ExpectedObjFilesAfterBuild => Enumerable.Concat(base.ExpectedObjFilesAfterBuild, new[]
|
||||||
|
{
|
||||||
|
$"{Name}.RazorCoreGenerate.cache",
|
||||||
|
$"{Name}.RazorTargetAssemblyInfo.cs",
|
||||||
|
$"{Name}.TagHelpers.input.cache",
|
||||||
|
$"{Name}.TagHelpers.output.cache",
|
||||||
|
$"{Name}.Views.dll",
|
||||||
|
$"{Name}.Views.pdb",
|
||||||
|
Path.Combine("Razor", "Pages", "_ViewImports.g.cshtml.cs"),
|
||||||
|
Path.Combine("Razor", "Pages", "_ViewStart.g.cshtml.cs"),
|
||||||
|
Path.Combine("Razor", "Pages", "About.g.cshtml.cs"),
|
||||||
|
Path.Combine("Razor", "Pages", "Contact.g.cshtml.cs"),
|
||||||
|
Path.Combine("Razor", "Pages", "Error.g.cshtml.cs"),
|
||||||
|
Path.Combine("Razor", "Pages", "Index.g.cshtml.cs"),
|
||||||
|
Path.Combine("Razor", "Pages", "Privacy.g.cshtml.cs"),
|
||||||
|
Path.Combine("Razor", "Pages", "Shared", "_CookieConsentPartial.g.cshtml.cs"),
|
||||||
|
Path.Combine("Razor", "Pages", "Shared", "_Layout.g.cshtml.cs"),
|
||||||
|
Path.Combine("Razor", "Pages", "Shared", "_ValidationScriptsPartial.g.cshtml.cs"),
|
||||||
|
}.Select(p => Path.Combine(OutputPath, p)));
|
||||||
|
|
||||||
|
public override IEnumerable<string> ExpectedBinFilesAfterBuild => Enumerable.Concat(base.ExpectedBinFilesAfterBuild, new[]
|
||||||
|
{
|
||||||
|
$"{Name}.Views.dll",
|
||||||
|
$"{Name}.Views.pdb",
|
||||||
|
}.Select(p => Path.Combine(OutputPath, p)));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -9,6 +9,7 @@ namespace AspNetCoreSdkTests.Templates
|
||||||
new ClassLibraryTemplate(),
|
new ClassLibraryTemplate(),
|
||||||
new ConsoleApplicationTemplate(),
|
new ConsoleApplicationTemplate(),
|
||||||
new WebTemplate(),
|
new WebTemplate(),
|
||||||
|
new RazorTemplate(),
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -8,14 +8,11 @@ namespace AspNetCoreSdkTests.Templates
|
||||||
{
|
{
|
||||||
public override string Name => "web";
|
public override string Name => "web";
|
||||||
|
|
||||||
public override TemplateType Type => TemplateType.Application;
|
|
||||||
|
|
||||||
public override IEnumerable<string> ExpectedObjFilesAfterBuild => Enumerable.Concat(base.ExpectedObjFilesAfterBuild, new[]
|
public override IEnumerable<string> ExpectedObjFilesAfterBuild => Enumerable.Concat(base.ExpectedObjFilesAfterBuild, new[]
|
||||||
{
|
{
|
||||||
$"{Name}.RazorAssemblyInfo.cache",
|
$"{Name}.RazorAssemblyInfo.cache",
|
||||||
$"{Name}.RazorAssemblyInfo.cs",
|
$"{Name}.RazorAssemblyInfo.cs",
|
||||||
$"{Name}.RazorTargetAssemblyInfo.cache",
|
$"{Name}.RazorTargetAssemblyInfo.cache",
|
||||||
}.Select(p => Path.Combine(OutputPath, p)));
|
}.Select(p => Path.Combine(OutputPath, p)));
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue