Fixup SDK workarounds (dotnet/aspnetcore-tooling#413)
* Correctly update the .NET Core SDK used in Razor
* Replace LangVersion 8.0 with LangVersion Preview
* Remove AddRazorSupportForMvc from projects that do not require it
* Cleanup how AspNetCore.App is not referenced in the project
* Remove uses of _RazorComponentInclude from tests\n\nCommit migrated from 81ea07caf7
This commit is contained in:
parent
607f64b386
commit
90eb9e8535
|
|
@ -114,7 +114,7 @@ Copyright (c) .NET Foundation. All rights reserved.
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<LangVersion Condition="'$(LangVersion)' == '' AND
|
<LangVersion Condition="'$(LangVersion)' == '' AND
|
||||||
(('$(TargetFrameworkIdentifier)' == '.NETCoreApp' AND '$(TargetFrameworkVersion)' == 'v3.0') OR
|
(('$(TargetFrameworkIdentifier)' == '.NETCoreApp' AND '$(TargetFrameworkVersion)' == 'v3.0') OR
|
||||||
('$(TargetFrameworkIdentifier)' == '.NETStandard' AND '$(TargetFrameworkVersion)' == 'v2.1'))">8.0</LangVersion>
|
('$(TargetFrameworkIdentifier)' == '.NETStandard' AND '$(TargetFrameworkVersion)' == 'v2.1'))">preview</LangVersion>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<Csc
|
<Csc
|
||||||
|
|
|
||||||
|
|
@ -77,8 +77,8 @@ namespace Microsoft.AspNetCore.Razor.Design.IntegrationTests
|
||||||
|
|
||||||
var filePaths = new string[]
|
var filePaths = new string[]
|
||||||
{
|
{
|
||||||
Path.Combine("MyComponent.cshtml"),
|
|
||||||
Path.Combine("GenericComponent.razor"),
|
Path.Combine("GenericComponent.razor"),
|
||||||
|
Path.Combine("MyComponent.razor"),
|
||||||
};
|
};
|
||||||
|
|
||||||
foreach (var filePath in filePaths)
|
foreach (var filePath in filePaths)
|
||||||
|
|
|
||||||
|
|
@ -5,18 +5,14 @@
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<DisableImplicitFrameworkReferences>true</DisableImplicitFrameworkReferences>
|
<TargetFramework>netcoreapp3.0</TargetFramework>
|
||||||
<AddRazorSupportForMvc>true</AddRazorSupportForMvc>
|
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<FrameworkReference Include="Microsoft.NETCore.App" />
|
<!-- Avoid referencing the AspNetCore framework since we want the ability to target work-in-progress shims -->
|
||||||
|
<FrameworkReference Remove="Microsoft.AspNetCore.App" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<PropertyGroup>
|
|
||||||
<TargetFramework>netcoreapp3.0</TargetFramework>
|
|
||||||
</PropertyGroup>
|
|
||||||
|
|
||||||
<PropertyGroup Condition="'$(RunningAsTest)' == ''">
|
<PropertyGroup Condition="'$(RunningAsTest)' == ''">
|
||||||
<!-- We don't want to run build server when not running as tests. -->
|
<!-- We don't want to run build server when not running as tests. -->
|
||||||
<UseRazorBuildServer>false</UseRazorBuildServer>
|
<UseRazorBuildServer>false</UseRazorBuildServer>
|
||||||
|
|
|
||||||
|
|
@ -4,19 +4,10 @@
|
||||||
<RazorSdkDirectoryRoot>$(RazorSdkArtifactsDirectory)$(Configuration)\sdk-output\</RazorSdkDirectoryRoot>
|
<RazorSdkDirectoryRoot>$(RazorSdkArtifactsDirectory)$(Configuration)\sdk-output\</RazorSdkDirectoryRoot>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<!--
|
|
||||||
The AspNetCore repo depends on AspNetCore-Tooling, and we want to avoid creating a cylical dependency between the two
|
|
||||||
by adding a reference to Microsoft.AspNetCore.App. We'll instead simulate the presence of the reference.
|
|
||||||
-->
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<DisableImplicitFrameworkReferences>true</DisableImplicitFrameworkReferences>
|
|
||||||
<AddRazorSupportForMvc>true</AddRazorSupportForMvc>
|
<AddRazorSupportForMvc>true</AddRazorSupportForMvc>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
|
||||||
<FrameworkReference Include="Microsoft.NETCore.App" />
|
|
||||||
</ItemGroup>
|
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFramework>netcoreapp3.0</TargetFramework>
|
<TargetFramework>netcoreapp3.0</TargetFramework>
|
||||||
<Copyright>© Microsoft</Copyright>
|
<Copyright>© Microsoft</Copyright>
|
||||||
|
|
|
||||||
|
|
@ -4,17 +4,9 @@
|
||||||
<RazorSdkDirectoryRoot>$(RazorSdkArtifactsDirectory)$(Configuration)\sdk-output\</RazorSdkDirectoryRoot>
|
<RazorSdkDirectoryRoot>$(RazorSdkArtifactsDirectory)$(Configuration)\sdk-output\</RazorSdkDirectoryRoot>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<PropertyGroup>
|
|
||||||
<DisableImplicitFrameworkReferences>true</DisableImplicitFrameworkReferences>
|
|
||||||
<AddRazorSupportForMvc>true</AddRazorSupportForMvc>
|
|
||||||
</PropertyGroup>
|
|
||||||
|
|
||||||
<ItemGroup>
|
|
||||||
<FrameworkReference Include="Microsoft.NETCore.App" />
|
|
||||||
</ItemGroup>
|
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFramework>netcoreapp3.0</TargetFramework>
|
<TargetFramework>netcoreapp3.0</TargetFramework>
|
||||||
|
<AddRazorSupportForMvc>true</AddRazorSupportForMvc>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<PropertyGroup Condition="'$(RunningAsTest)' == ''">
|
<PropertyGroup Condition="'$(RunningAsTest)' == ''">
|
||||||
|
|
|
||||||
|
|
@ -2,17 +2,15 @@
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<RazorSdkDirectoryRoot>$(RazorSdkArtifactsDirectory)$(Configuration)\sdk-output\</RazorSdkDirectoryRoot>
|
<RazorSdkDirectoryRoot>$(RazorSdkArtifactsDirectory)$(Configuration)\sdk-output\</RazorSdkDirectoryRoot>
|
||||||
<AddRazorSupportForMvc>true</AddRazorSupportForMvc>
|
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFramework>netcoreapp3.0</TargetFramework>
|
<TargetFramework>netcoreapp3.0</TargetFramework>
|
||||||
<DisableImplicitFrameworkReferences>true</DisableImplicitFrameworkReferences>
|
|
||||||
<LangVersion>8.0</LangVersion>
|
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<FrameworkReference Include="Microsoft.NETCore.App" />
|
<!-- Avoid referencing the AspNetCore framework since we want the ability to target work-in-progress shims -->
|
||||||
|
<FrameworkReference Remove="Microsoft.AspNetCore.App" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<PropertyGroup Condition="'$(RunningAsTest)' == ''">
|
<PropertyGroup Condition="'$(RunningAsTest)' == ''">
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,6 @@
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<RazorSdkDirectoryRoot>$(RazorSdkArtifactsDirectory)$(Configuration)\sdk-output\</RazorSdkDirectoryRoot>
|
<RazorSdkDirectoryRoot>$(RazorSdkArtifactsDirectory)$(Configuration)\sdk-output\</RazorSdkDirectoryRoot>
|
||||||
<_RazorComponentInclude>**\*.cshtml</_RazorComponentInclude>
|
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
|
|
|
||||||
|
|
@ -2,22 +2,17 @@
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<RazorSdkDirectoryRoot>$(RazorSdkArtifactsDirectory)$(Configuration)\sdk-output\</RazorSdkDirectoryRoot>
|
<RazorSdkDirectoryRoot>$(RazorSdkArtifactsDirectory)$(Configuration)\sdk-output\</RazorSdkDirectoryRoot>
|
||||||
<_RazorComponentInclude>Components\**\*.cshtml</_RazorComponentInclude>
|
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<PropertyGroup>
|
|
||||||
<DisableImplicitFrameworkReferences>true</DisableImplicitFrameworkReferences>
|
|
||||||
<AddRazorSupportForMvc>true</AddRazorSupportForMvc>
|
|
||||||
</PropertyGroup>
|
|
||||||
|
|
||||||
<ItemGroup>
|
|
||||||
<FrameworkReference Include="Microsoft.NETCore.App" />
|
|
||||||
</ItemGroup>
|
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFramework>netcoreapp3.0</TargetFramework>
|
<TargetFramework>netcoreapp3.0</TargetFramework>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<!-- Avoid referencing the AspNetCore framework since we want the ability to target work-in-progress shims -->
|
||||||
|
<FrameworkReference Remove="Microsoft.AspNetCore.App" />
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
<PropertyGroup Condition="'$(RunningAsTest)' == ''">
|
<PropertyGroup Condition="'$(RunningAsTest)' == ''">
|
||||||
<!-- We don't want to run build server when not running as tests. -->
|
<!-- We don't want to run build server when not running as tests. -->
|
||||||
<UseRazorBuildServer>false</UseRazorBuildServer>
|
<UseRazorBuildServer>false</UseRazorBuildServer>
|
||||||
|
|
|
||||||
|
|
@ -5,18 +5,14 @@
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<DisableImplicitFrameworkReferences>true</DisableImplicitFrameworkReferences>
|
<TargetFramework>netcoreapp3.0</TargetFramework>
|
||||||
<AddRazorSupportForMvc>true</AddRazorSupportForMvc>
|
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<FrameworkReference Include="Microsoft.NETCore.App" />
|
<!-- Avoid referencing the AspNetCore framework since we want the ability to target work-in-progress shims -->
|
||||||
|
<FrameworkReference Remove="Microsoft.AspNetCore.App" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<PropertyGroup>
|
|
||||||
<TargetFramework>netcoreapp3.0</TargetFramework>
|
|
||||||
</PropertyGroup>
|
|
||||||
|
|
||||||
<PropertyGroup Condition="'$(RunningAsTest)' == ''">
|
<PropertyGroup Condition="'$(RunningAsTest)' == ''">
|
||||||
<!-- We don't want to run build server when not running as tests. -->
|
<!-- We don't want to run build server when not running as tests. -->
|
||||||
<UseRazorBuildServer>false</UseRazorBuildServer>
|
<UseRazorBuildServer>false</UseRazorBuildServer>
|
||||||
|
|
|
||||||
|
|
@ -5,17 +5,14 @@
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<DisableImplicitFrameworkReferences>true</DisableImplicitFrameworkReferences>
|
<TargetFramework>netcoreapp3.0</TargetFramework>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<FrameworkReference Include="Microsoft.NETCore.App" />
|
<!-- Avoid referencing the AspNetCore framework since we want the ability to target work-in-progress shims -->
|
||||||
|
<FrameworkReference Remove="Microsoft.AspNetCore.App" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<PropertyGroup>
|
|
||||||
<TargetFramework>netcoreapp3.0</TargetFramework>
|
|
||||||
</PropertyGroup>
|
|
||||||
|
|
||||||
<PropertyGroup Condition="'$(RunningAsTest)' == ''">
|
<PropertyGroup Condition="'$(RunningAsTest)' == ''">
|
||||||
<!-- We don't want to run build server when not running as tests. -->
|
<!-- We don't want to run build server when not running as tests. -->
|
||||||
<UseRazorBuildServer>false</UseRazorBuildServer>
|
<UseRazorBuildServer>false</UseRazorBuildServer>
|
||||||
|
|
|
||||||
|
|
@ -5,18 +5,14 @@
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<DisableImplicitFrameworkReferences>true</DisableImplicitFrameworkReferences>
|
<TargetFramework>netcoreapp3.0</TargetFramework>
|
||||||
<AddRazorSupportForMvc>true</AddRazorSupportForMvc>
|
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<FrameworkReference Include="Microsoft.NETCore.App" />
|
<!-- Avoid referencing the AspNetCore framework since we want the ability to target work-in-progress shims -->
|
||||||
|
<FrameworkReference Remove="Microsoft.AspNetCore.App" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<PropertyGroup>
|
|
||||||
<TargetFramework>netcoreapp3.0</TargetFramework>
|
|
||||||
</PropertyGroup>
|
|
||||||
|
|
||||||
<PropertyGroup Condition="'$(RunningAsTest)' == ''">
|
<PropertyGroup Condition="'$(RunningAsTest)' == ''">
|
||||||
<!-- We don't want to run build server when not running as tests. -->
|
<!-- We don't want to run build server when not running as tests. -->
|
||||||
<UseRazorBuildServer>false</UseRazorBuildServer>
|
<UseRazorBuildServer>false</UseRazorBuildServer>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue