[release/5.0.1xx-preview2] Update dependencies from dotnet/templating (#6819)
* Update dependencies from https://github.com/dotnet/templating build 20200314.2 - Microsoft.DotNet.Common.ItemTemplates - 5.0.0-preview.2.20164.2 * Update dependencies from https://github.com/dotnet/templating build 20200314.4 - Microsoft.DotNet.Common.ItemTemplates - 5.0.0-preview.2.20164.4 * Update template tests * Concat net tfms instead of replacing Co-authored-by: dotnet-maestro[bot] <dotnet-maestro[bot]@users.noreply.github.com> Co-authored-by: Viktor Hofer <viktor.hofer@microsoft.com>
This commit is contained in:
parent
b5bccca3f5
commit
e99dc08b36
4 changed files with 30 additions and 45 deletions
|
@ -2,33 +2,34 @@
|
|||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using Xunit;
|
||||
|
||||
namespace EndToEnd
|
||||
{
|
||||
public static class TargetFrameworkHelper
|
||||
{
|
||||
private static Version _firstNetAppVersion = new Version(5, 0);
|
||||
|
||||
public static IEnumerable<string> GetNetAppTargetFrameworks(IEnumerable<string> versions) =>
|
||||
versions.Select(v => $"netcoreapp{v}")
|
||||
// Add netX.X tfms starting with 5.0
|
||||
.Concat(versions.Where(v => Version.Parse(v) >= _firstNetAppVersion).Select(v => $"net{v}"));
|
||||
}
|
||||
|
||||
public class SupportedNetCoreAppVersions : IEnumerable<object[]>
|
||||
{
|
||||
public IEnumerator<object[]> GetEnumerator() => Versions.Select(version => new object[] { version }).GetEnumerator();
|
||||
IEnumerator IEnumerable.GetEnumerator() => GetEnumerator();
|
||||
public static IEnumerable<string> Versions
|
||||
public static IEnumerable<string> Versions => new[]
|
||||
{
|
||||
get
|
||||
{
|
||||
return new[]
|
||||
{
|
||||
"1.0",
|
||||
"1.1",
|
||||
"2.0",
|
||||
"2.1",
|
||||
"2.2",
|
||||
"3.0",
|
||||
"3.1",
|
||||
"5.0"
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
"1.0",
|
||||
"1.1",
|
||||
"2.0",
|
||||
"2.1",
|
||||
"2.2",
|
||||
"3.0",
|
||||
"3.1",
|
||||
"5.0"
|
||||
};
|
||||
}
|
||||
|
||||
public class SupportedAspNetCoreVersions : IEnumerable<object[]>
|
||||
|
@ -36,13 +37,8 @@ namespace EndToEnd
|
|||
public IEnumerator<object[]> GetEnumerator() => Versions.Select(version => new object[] { version }).GetEnumerator();
|
||||
IEnumerator IEnumerable.GetEnumerator() => GetEnumerator();
|
||||
|
||||
public static IEnumerable<string> Versions
|
||||
{
|
||||
get
|
||||
{
|
||||
return SupportedNetCoreAppVersions.Versions.Except(new List<string>() { "1.0", "1.1", "2.0" });
|
||||
}
|
||||
}
|
||||
public static IEnumerable<string> Versions =>
|
||||
SupportedNetCoreAppVersions.Versions.Except(new List<string>() { "1.0", "1.1", "2.0" });
|
||||
}
|
||||
|
||||
public class SupportedAspNetCoreAllVersions : IEnumerable<object[]>
|
||||
|
@ -50,12 +46,7 @@ namespace EndToEnd
|
|||
public IEnumerator<object[]> GetEnumerator() => Versions.Select(version => new object[] { version }).GetEnumerator();
|
||||
IEnumerator IEnumerable.GetEnumerator() => GetEnumerator();
|
||||
|
||||
public static IEnumerable<string> Versions
|
||||
{
|
||||
get
|
||||
{
|
||||
return SupportedAspNetCoreVersions.Versions.Where(v => new Version(v).Major < 3);
|
||||
}
|
||||
}
|
||||
public static IEnumerable<string> Versions =>
|
||||
SupportedAspNetCoreVersions.Versions.Where(v => new Version(v).Major < 3);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue