Integrate new WebSDK
One of these tests had to be updated and split into two because the expectations of the test weren't totally right. I also logged https://github.com/aspnet/Razor/issues/1986 during this, we didn't consider the impact of putting this logic in the WebSDK on class library.
This commit is contained in:
parent
3e449ec3de
commit
02200d4c11
|
|
@ -74,14 +74,28 @@ namespace Microsoft.AspNetCore.Razor.Design.IntegrationTests
|
|||
Assert.FileCountEquals(result, 0, Path.Combine(PublishOutputPath, "Views"), "*.cshtml");
|
||||
}
|
||||
|
||||
[Fact]
|
||||
[Fact] // This will use the old precompilation tool, RazorSDK shouldn't get involved.
|
||||
[InitializeTestProject("SimpleMvc")]
|
||||
public async Task Publish_WithMvcRazorCompileOnPublish_PublishesAssembly()
|
||||
public async Task Publish_WithMvcRazorCompileOnPublish_Noops()
|
||||
{
|
||||
var result = await DotnetMSBuild("Publish", "/p:MvcRazorCompileOnPublish=true");
|
||||
|
||||
Assert.BuildPassed(result);
|
||||
|
||||
Assert.FileExists(result, PublishOutputPath, "SimpleMvc.dll");
|
||||
Assert.FileExists(result, PublishOutputPath, "SimpleMvc.pdb");
|
||||
Assert.FileDoesNotExist(result, PublishOutputPath, "SimpleMvc.PrecompiledViews.dll");
|
||||
Assert.FileDoesNotExist(result, PublishOutputPath, "SimpleMvc.PrecompiledViews.pdb");
|
||||
}
|
||||
|
||||
[Fact] // This is an override to force the new toolset
|
||||
[InitializeTestProject("SimpleMvc")]
|
||||
public async Task Publish_WithMvcRazorCompileOnPublish_AndRazorSDK_PublishesAssembly()
|
||||
{
|
||||
var result = await DotnetMSBuild("Publish", "/p:MvcRazorCompileOnPublish=true /p:ResolvedRazorCompileToolset=RazorSDK");
|
||||
|
||||
Assert.BuildPassed(result);
|
||||
|
||||
Assert.FileDoesNotExist(result, OutputPath, "SimpleMvc.PrecompiledViews.dll");
|
||||
Assert.FileDoesNotExist(result, OutputPath, "SimpleMvc.PrecompiledViews.pdb");
|
||||
|
||||
|
|
|
|||
|
|
@ -1,9 +1,6 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk.Web">
|
||||
<PropertyGroup>
|
||||
<TargetFramework>netcoreapp2.0</TargetFramework>
|
||||
|
||||
<!-- Workaround until we get a new SDK build -->
|
||||
<ResolvedRazorCompileToolset Condition="'$(RazorCompileToolset)'==''">RazorSDK</ResolvedRazorCompileToolset>
|
||||
</PropertyGroup>
|
||||
|
||||
<!-- Test Placeholder -->
|
||||
|
|
|
|||
|
|
@ -2,8 +2,8 @@
|
|||
<PropertyGroup>
|
||||
<TargetFramework>netcoreapp2.0</TargetFramework>
|
||||
|
||||
<!-- Workaround until we get a new SDK build -->
|
||||
<ResolvedRazorCompileToolset Condition="'$(RazorCompileToolset)'==''">RazorSDK</ResolvedRazorCompileToolset>
|
||||
<!-- This is needed without a reference to the Web SDK. See: #1986 -->
|
||||
<ResolvedRazorCompileToolset>RazorSDK</ResolvedRazorCompileToolset>
|
||||
</PropertyGroup>
|
||||
|
||||
<!-- Test Placeholder -->
|
||||
|
|
|
|||
|
|
@ -1,9 +1,6 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk.Web">
|
||||
<PropertyGroup>
|
||||
<TargetFramework>netcoreapp2.0</TargetFramework>
|
||||
|
||||
<!-- Workaround until we get a new SDK build -->
|
||||
<ResolvedRazorCompileToolset Condition="'$(RazorCompileToolset)'==''">RazorSDK</ResolvedRazorCompileToolset>
|
||||
</PropertyGroup>
|
||||
|
||||
<!-- Test Placeholder -->
|
||||
|
|
|
|||
|
|
@ -1,9 +1,6 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk.Web">
|
||||
<PropertyGroup>
|
||||
<TargetFramework>netcoreapp2.0</TargetFramework>
|
||||
|
||||
<!-- Workaround until we get a new SDK build -->
|
||||
<ResolvedRazorCompileToolset Condition="'$(RazorCompileToolset)'==''">RazorSDK</ResolvedRazorCompileToolset>
|
||||
</PropertyGroup>
|
||||
|
||||
<!-- Test Placeholder -->
|
||||
|
|
|
|||
Loading…
Reference in New Issue