Converted test projects and samples to run on netcoreapp2.0
This commit is contained in:
parent
9e9dc727ca
commit
7124247b50
|
|
@ -3,6 +3,7 @@
|
|||
<AspNetCoreVersion>1.2.0-*</AspNetCoreVersion>
|
||||
<CoreFxVersion>4.3.0</CoreFxVersion>
|
||||
<NetStandardImplicitPackageVersion>1.6.1</NetStandardImplicitPackageVersion>
|
||||
<RuntimeFrameworkVersion>2.0.0-*</RuntimeFrameworkVersion>
|
||||
<SystemReflectionMetadataVersion>1.4.2</SystemReflectionMetadataVersion>
|
||||
<TestSdkVersion>15.0.0</TestSdkVersion>
|
||||
<WebAdministrationVersion>7.0.0</WebAdministrationVersion>
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
<Import Project="..\..\build\dependencies.props" />
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>net451;netcoreapp1.1</TargetFrameworks>
|
||||
<TargetFrameworks>net451;netcoreapp2.0</TargetFrameworks>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
<Import Project="..\..\build\common.props" />
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>netcoreapp1.1</TargetFramework>
|
||||
<TargetFramework>netcoreapp2.0</TargetFramework>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
|
|
|||
|
|
@ -3,8 +3,8 @@
|
|||
<Import Project="..\..\build\common.props" />
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>net452;netcoreapp1.1</TargetFrameworks>
|
||||
<TargetFrameworks Condition=" '$(OS)' != 'Windows_NT' ">netcoreapp1.1</TargetFrameworks>
|
||||
<TargetFrameworks>netcoreapp2.0;net452</TargetFrameworks>
|
||||
<TargetFrameworks Condition=" '$(OS)' != 'Windows_NT' ">netcoreapp2.0</TargetFrameworks>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
|
|
|||
|
|
@ -43,8 +43,11 @@ namespace Microsoft.AspNetCore.Hosting.Internal
|
|||
var eventData = eventListener.EventData;
|
||||
Assert.NotNull(eventData);
|
||||
Assert.Equal(expectedEventId, eventData.EventId);
|
||||
#if NETCOREAPP1_1
|
||||
#if NETCOREAPP2_0
|
||||
Assert.Equal("HostStart", eventData.EventName);
|
||||
#elif NET452
|
||||
#else
|
||||
#error Target framework needs to be updated
|
||||
#endif
|
||||
Assert.Equal(EventLevel.Informational, eventData.Level);
|
||||
Assert.Same(hostingEventSource, eventData.EventSource);
|
||||
|
|
@ -68,8 +71,11 @@ namespace Microsoft.AspNetCore.Hosting.Internal
|
|||
var eventData = eventListener.EventData;
|
||||
Assert.NotNull(eventData);
|
||||
Assert.Equal(expectedEventId, eventData.EventId);
|
||||
#if NETCOREAPP1_1
|
||||
#if NETCOREAPP2_0
|
||||
Assert.Equal("HostStop", eventData.EventName);
|
||||
#elif NET452
|
||||
#else
|
||||
#error Target framework needs to be updated
|
||||
#endif
|
||||
Assert.Equal(EventLevel.Informational, eventData.Level);
|
||||
Assert.Same(hostingEventSource, eventData.EventSource);
|
||||
|
|
@ -126,8 +132,11 @@ namespace Microsoft.AspNetCore.Hosting.Internal
|
|||
var eventData = eventListener.EventData;
|
||||
Assert.NotNull(eventData);
|
||||
Assert.Equal(expectedEventId, eventData.EventId);
|
||||
#if NETCOREAPP1_1
|
||||
#if NETCOREAPP2_0
|
||||
Assert.Equal("RequestStart", eventData.EventName);
|
||||
#elif NET452
|
||||
#else
|
||||
#error Target framework needs to be updated
|
||||
#endif
|
||||
Assert.Equal(EventLevel.Informational, eventData.Level);
|
||||
Assert.Same(hostingEventSource, eventData.EventSource);
|
||||
|
|
@ -156,8 +165,11 @@ namespace Microsoft.AspNetCore.Hosting.Internal
|
|||
// Assert
|
||||
var eventData = eventListener.EventData;
|
||||
Assert.Equal(expectedEventId, eventData.EventId);
|
||||
#if NETCOREAPP1_1
|
||||
#if NETCOREAPP2_0
|
||||
Assert.Equal("RequestStop", eventData.EventName);
|
||||
#elif NET452
|
||||
#else
|
||||
#error Target framework needs to be updated
|
||||
#endif
|
||||
Assert.Equal(EventLevel.Informational, eventData.Level);
|
||||
Assert.Same(hostingEventSource, eventData.EventSource);
|
||||
|
|
@ -180,8 +192,11 @@ namespace Microsoft.AspNetCore.Hosting.Internal
|
|||
// Assert
|
||||
var eventData = eventListener.EventData;
|
||||
Assert.Equal(expectedEventId, eventData.EventId);
|
||||
#if NETCOREAPP1_1
|
||||
#if NETCOREAPP2_0
|
||||
Assert.Equal("UnhandledException", eventData.EventName);
|
||||
#elif NET452
|
||||
#else
|
||||
#error Target framework needs to be updated
|
||||
#endif
|
||||
Assert.Equal(EventLevel.Error, eventData.Level);
|
||||
Assert.Same(hostingEventSource, eventData.EventSource);
|
||||
|
|
|
|||
|
|
@ -3,8 +3,8 @@
|
|||
<Import Project="..\..\build\common.props" />
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>netcoreapp1.1;net452</TargetFrameworks>
|
||||
<TargetFrameworks Condition=" '$(OS)' != 'Windows_NT' ">netcoreapp1.1</TargetFrameworks>
|
||||
<TargetFrameworks>netcoreapp2.0;net452</TargetFrameworks>
|
||||
<TargetFrameworks Condition=" '$(OS)' != 'Windows_NT' ">netcoreapp2.0</TargetFrameworks>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
|
|
|||
|
|
@ -3,8 +3,8 @@
|
|||
<Import Project="..\..\build\common.props" />
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>netcoreapp1.1;net452</TargetFrameworks>
|
||||
<TargetFrameworks Condition=" '$(OS)' != 'Windows_NT' ">netcoreapp1.1</TargetFrameworks>
|
||||
<TargetFrameworks>netcoreapp2.0;net452</TargetFrameworks>
|
||||
<TargetFrameworks Condition=" '$(OS)' != 'Windows_NT' ">netcoreapp2.0</TargetFrameworks>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
|
|
|||
Loading…
Reference in New Issue