Update tests for .NET 6
This commit is contained in:
parent
66318e6fc4
commit
9ec9fce35e
5 changed files with 11 additions and 19 deletions
|
@ -1,7 +1,7 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
<PropertyGroup>
|
||||
<OutputType>Exe</OutputType>
|
||||
<TargetFramework>net5.0</TargetFramework>
|
||||
<TargetFramework>net6.0</TargetFramework>
|
||||
<TargetPlatformIdentifier>Windows</TargetPlatformIdentifier>
|
||||
</PropertyGroup>
|
||||
</Project>
|
||||
|
|
|
@ -29,10 +29,13 @@
|
|||
<_NETCorePlatformsPackageVersion>$(MicrosoftNETCorePlatformsPackageVersion)</_NETCorePlatformsPackageVersion>
|
||||
|
||||
<!-- TODO: Once .NET 5.0 has released, update these version numbers to 5.0.0 -->
|
||||
<_NET50DefaultRuntimeFrameworkVersion>5.0.0-rc.2.20475.5</_NET50DefaultRuntimeFrameworkVersion>
|
||||
<_NET50RuntimePackVersion>5.0.0-rc.2.20475.5</_NET50RuntimePackVersion>
|
||||
<_NET50TargetingPackVersion>5.0.0-rc.2.20475.5</_NET50TargetingPackVersion>
|
||||
<_WindowsDesktop50DefaultRuntimeFrameworkVersion>5.0.0-rc.2.20475.6</_WindowsDesktop50DefaultRuntimeFrameworkVersion>
|
||||
<_WindowsDesktop50RuntimePackVersion>5.0.0-rc.2.20475.6</_WindowsDesktop50RuntimePackVersion>
|
||||
<_WindowsDesktop50TargetingPackVersion>5.0.0-rc.2.20475.6</_WindowsDesktop50TargetingPackVersion>
|
||||
<_AspNet50DefaultRuntimeFrameworkVersion>5.0.0-rc.2.20475.17</_AspNet50DefaultRuntimeFrameworkVersion>
|
||||
<_AspNet50RuntimePackVersion>5.0.0-rc.2.20475.17</_AspNet50RuntimePackVersion>
|
||||
<_AspNet50TargetingPackVersion>5.0.0-rc.2.20475.17</_AspNet50TargetingPackVersion>
|
||||
|
||||
|
@ -331,7 +334,7 @@ Copyright (c) .NET Foundation. All rights reserved.
|
|||
<KnownFrameworkReference Include="Microsoft.NETCore.App"
|
||||
TargetFramework="net5.0"
|
||||
RuntimeFrameworkName="Microsoft.NETCore.App"
|
||||
DefaultRuntimeFrameworkVersion="5.0.0"
|
||||
DefaultRuntimeFrameworkVersion="$(_NET50DefaultRuntimeFrameworkVersion)"
|
||||
LatestRuntimeFrameworkVersion="$(_NET50RuntimePackVersion)"
|
||||
TargetingPackName="Microsoft.NETCore.App.Ref"
|
||||
TargetingPackVersion="$(_NET50TargetingPackVersion)"
|
||||
|
@ -357,7 +360,7 @@ Copyright (c) .NET Foundation. All rights reserved.
|
|||
<KnownFrameworkReference Include="Microsoft.WindowsDesktop.App"
|
||||
TargetFramework="net5.0"
|
||||
RuntimeFrameworkName="Microsoft.WindowsDesktop.App"
|
||||
DefaultRuntimeFrameworkVersion="5.0.0"
|
||||
DefaultRuntimeFrameworkVersion="$(_WindowsDesktop50DefaultRuntimeFrameworkVersion)"
|
||||
LatestRuntimeFrameworkVersion="$(_WindowsDesktop50RuntimePackVersion)"
|
||||
TargetingPackName="Microsoft.WindowsDesktop.App.Ref"
|
||||
TargetingPackVersion="$(_WindowsDesktop50TargetingPackVersion)"
|
||||
|
@ -369,7 +372,7 @@ Copyright (c) .NET Foundation. All rights reserved.
|
|||
<KnownFrameworkReference Include="Microsoft.WindowsDesktop.App.WPF"
|
||||
TargetFramework="net5.0"
|
||||
RuntimeFrameworkName="Microsoft.WindowsDesktop.App"
|
||||
DefaultRuntimeFrameworkVersion="5.0.0"
|
||||
DefaultRuntimeFrameworkVersion="$(_WindowsDesktop50DefaultRuntimeFrameworkVersion)"
|
||||
LatestRuntimeFrameworkVersion="$(_WindowsDesktop50RuntimePackVersion)"
|
||||
TargetingPackName="Microsoft.WindowsDesktop.App.Ref"
|
||||
TargetingPackVersion="$(_WindowsDesktop50TargetingPackVersion)"
|
||||
|
@ -382,7 +385,7 @@ Copyright (c) .NET Foundation. All rights reserved.
|
|||
<KnownFrameworkReference Include="Microsoft.WindowsDesktop.App.WindowsForms"
|
||||
TargetFramework="net5.0"
|
||||
RuntimeFrameworkName="Microsoft.WindowsDesktop.App"
|
||||
DefaultRuntimeFrameworkVersion="5.0.0"
|
||||
DefaultRuntimeFrameworkVersion="$(_WindowsDesktop50DefaultRuntimeFrameworkVersion)"
|
||||
LatestRuntimeFrameworkVersion="$(_WindowsDesktop50RuntimePackVersion)"
|
||||
TargetingPackName="Microsoft.WindowsDesktop.App.Ref"
|
||||
TargetingPackVersion="$(_WindowsDesktop50TargetingPackVersion)"
|
||||
|
@ -395,7 +398,7 @@ Copyright (c) .NET Foundation. All rights reserved.
|
|||
<KnownFrameworkReference Include="Microsoft.AspNetCore.App"
|
||||
TargetFramework="net5.0"
|
||||
RuntimeFrameworkName="Microsoft.AspNetCore.App"
|
||||
DefaultRuntimeFrameworkVersion="5.0.0"
|
||||
DefaultRuntimeFrameworkVersion="$(_AspNet50DefaultRuntimeFrameworkVersion)"
|
||||
LatestRuntimeFrameworkVersion="$(_AspNet50RuntimePackVersion)"
|
||||
TargetingPackName="Microsoft.AspNetCore.App.Ref"
|
||||
TargetingPackVersion="$(_AspNet50TargetingPackVersion)"
|
||||
|
|
|
@ -17,7 +17,7 @@ namespace Microsoft.DotNet.Tests.EndToEnd
|
|||
{
|
||||
var testProjectCreator = new TestProjectCreator()
|
||||
{
|
||||
MinorVersion = "5.0"
|
||||
MinorVersion = "6.0"
|
||||
};
|
||||
|
||||
testProjectCreator.AdditionalProperties["RestorePackagesPath"] = @"$(MSBuildProjectDirectory)\packages";
|
||||
|
|
|
@ -10,7 +10,7 @@ using Xunit;
|
|||
|
||||
namespace EndToEnd
|
||||
{
|
||||
public class GivenWindows50App : TestBase
|
||||
public class GivenWindowsApp : TestBase
|
||||
{
|
||||
[WindowsOnlyTheory]
|
||||
[InlineData("10.0.17763.0")]
|
|
@ -40,16 +40,5 @@ namespace Microsoft.DotNet.Tools.Test.Utilities
|
|||
.FailWith($"Expected File {_fileInfo.FullName} to not exist, but it does.");
|
||||
return new AndConstraint<FileInfoAssertions>(this);
|
||||
}
|
||||
|
||||
public AndWhichConstraint<FileInfoAssertions, DateTimeOffset> HaveLastWriteTimeUtc(string because = "", params object[] reasonArgs)
|
||||
{
|
||||
var lastWriteTimeUtc = _fileInfo.LastWriteTimeUtc;
|
||||
|
||||
Execute.Assertion
|
||||
.ForCondition(lastWriteTimeUtc != null)
|
||||
.BecauseOf(because, reasonArgs)
|
||||
.FailWith($"Expected File {_fileInfo.FullName} to have a LastWriteTimeUTC, but it is null.");
|
||||
return new AndWhichConstraint<FileInfoAssertions, DateTimeOffset>(this, lastWriteTimeUtc);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue