parent
af91b58bd3
commit
3448b6a74e
|
|
@ -7,6 +7,7 @@ using System.Net.Http.Headers;
|
|||
using System.Text.Encodings.Web;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.AspNetCore.Mvc.Razor.Internal;
|
||||
using Microsoft.AspNetCore.Testing.xunit;
|
||||
using Xunit;
|
||||
|
||||
namespace Microsoft.AspNetCore.Mvc.FunctionalTests
|
||||
|
|
@ -91,7 +92,12 @@ namespace Microsoft.AspNetCore.Mvc.FunctionalTests
|
|||
Assert.Contains(expectedCompilationContent, content);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
[ConditionalFact]
|
||||
// MVC Generates portable PDBs when compiling Razor views. NET461 does not understand portable PDBs
|
||||
// so line and file information cannot be determined. This is blocked until one of these issues are fixed:
|
||||
// https://github.com/aspnet/Common/issues/235
|
||||
// https://github.com/aspnet/Mvc/issues/6356
|
||||
[FrameworkSkipCondition(RuntimeFrameworks.CLR)]
|
||||
public async Task RuntimeErrorAreListedByErrorPageMiddleware()
|
||||
{
|
||||
// Arrange
|
||||
|
|
|
|||
|
|
@ -2,13 +2,21 @@
|
|||
<Import Project="..\..\build\common.props" />
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>netcoreapp2.0</TargetFrameworks>
|
||||
<TargetFrameworks>netcoreapp2.0;net461</TargetFrameworks>
|
||||
<TargetFrameworks Condition=" '$(OS)' != 'Windows_NT' ">netcoreapp2.0</TargetFrameworks>
|
||||
<PackageTargetFallback Condition=" '$(TargetFramework)' == 'netcoreapp2.0' ">$(PackageTargetFallback);portable-net451+win8</PackageTargetFallback>
|
||||
|
||||
<DefineConstants Condition="'$(GenerateBaselines)'=='true'">$(DefineConstants);GENERATE_BASELINES</DefineConstants>
|
||||
<DefineConstants>$(DefineConstants);__RemoveThisBitTo__GENERATE_BASELINES</DefineConstants>
|
||||
<DefineConstants>$(DefineConstants);FUNCTIONAL_TESTS</DefineConstants>
|
||||
|
||||
<!--
|
||||
The functional tests act as the host application for all test websites. Since the CLI copies all reference
|
||||
assembly dependencies in websites to their corresponding bin/{config}/refs folder we need to re-calculate
|
||||
reference assemblies for this project so there's a corresponding refs folder in our output. Without it
|
||||
our websites deps files will fail to find their assembly referenes.
|
||||
-->
|
||||
<PreserveCompilationContext>true</PreserveCompilationContext>
|
||||
</PropertyGroup>
|
||||
|
||||
<PropertyGroup Condition=" '$(TargetFramework)' != 'netcoreapp2.0' ">
|
||||
|
|
|
|||
|
|
@ -62,6 +62,11 @@ namespace Microsoft.AspNetCore.Mvc.FunctionalTests
|
|||
{
|
||||
typeof(JsonMediaTypeFormatter).FullName,
|
||||
typeof(XmlMediaTypeFormatter).FullName,
|
||||
|
||||
#if NET461
|
||||
// We call into WebAPI and ask it to add all of its formatters. On net461 it adds this additional formatter.
|
||||
typeof(FormUrlEncodedMediaTypeFormatter).FullName
|
||||
#endif
|
||||
};
|
||||
|
||||
// Act
|
||||
|
|
|
|||
Loading…
Reference in New Issue