Skip to content

Commit

Permalink
.net 8
Browse files Browse the repository at this point in the history
  • Loading branch information
KSemenenko committed May 27, 2024
1 parent a0b9092 commit 0a1d577
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 23 deletions.
4 changes: 2 additions & 2 deletions Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@
<RepositoryUrl>https://github.com/managedcode/EnvironmentDetector</RepositoryUrl>
<PackageProjectUrl>https://github.com/managedcode/EnvironmentDetector</PackageProjectUrl>
<Product>Managed Code - EnvironmentDetector</Product>
<Version>1.0.5</Version>
<PackageVersion>1.0.5</PackageVersion>
<Version>1.0.8</Version>
<PackageVersion>1.0.8</PackageVersion>

</PropertyGroup>
<PropertyGroup Condition="'$(GITHUB_ACTIONS)' == 'true'">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<PropertyGroup>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<TargetFrameworks>net6.0;net7.0;netstandard2.1</TargetFrameworks>
<TargetFrameworks>net6.0;net7.0;netstandard2.1;net8.0</TargetFrameworks>
<LangVersion>11</LangVersion>
</PropertyGroup>

Expand All @@ -15,7 +15,7 @@
<PackageTags>managedcode, Tests, Detector, TestsDetector, unit tests</PackageTags>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Microsoft.Extensions.Hosting.Abstractions" Version="7.0.0" />
<PackageReference Include="Microsoft.Extensions.Hosting.Abstractions" Version="8.0.0" />
</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net7.0</TargetFramework>
<TargetFramework>net8.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<IsPackable>false</IsPackable>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.4.1" />
<PackageReference Include="MSTest.TestAdapter" Version="3.0.0" />
<PackageReference Include="MSTest.TestFramework" Version="3.0.0" />
<PackageReference Include="coverlet.collector" Version="3.2.0">
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.10.0" />
<PackageReference Include="MSTest.TestAdapter" Version="3.4.0" />
<PackageReference Include="MSTest.TestFramework" Version="3.4.0" />
<PackageReference Include="coverlet.collector" Version="6.0.2">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net7.0</TargetFramework>
<TargetFramework>net8.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<IsPackable>false</IsPackable>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.4.1" />
<PackageReference Include="NUnit" Version="3.13.3" />
<PackageReference Include="NUnit3TestAdapter" Version="4.3.1" />
<PackageReference Include="coverlet.collector" Version="3.2.0">
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.10.0" />
<PackageReference Include="NUnit" Version="4.1.0" />
<PackageReference Include="NUnit3TestAdapter" Version="4.5.0" />
<PackageReference Include="coverlet.collector" Version="6.0.2">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
Expand Down
9 changes: 5 additions & 4 deletions ManagedCode.TestsDetector.NUnit/Tests.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
using ManagedCode.EnvironmentDetector;
using NUnit.Framework;
using NUnit.Framework.Legacy;

namespace ManagedCode.TestsDetector.NUnit;

Expand All @@ -9,24 +10,24 @@ public class Tests
[Test]
public void TestDetectorTest()
{
Assert.IsTrue(TestDetector.IsInTest);
ClassicAssert.IsTrue(TestDetector.IsInTest);
}

[Test]
public void MSTestDetectorTest()
{
Assert.IsFalse(MSTestDetector.IsInTest);
ClassicAssert.IsFalse(MSTestDetector.IsInTest);
}

[Test]
public void NUnitDetectorTest()
{
Assert.IsTrue(NUnitDetector.IsInTest);
ClassicAssert.IsTrue(NUnitDetector.IsInTest);
}

[Test]
public void XUnitDetectorTest()
{
Assert.IsFalse(XUnitDetector.IsInTest);
ClassicAssert.IsFalse(XUnitDetector.IsInTest);
}
}
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net7.0</TargetFramework>
<TargetFramework>net8.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<IsPackable>false</IsPackable>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.4.1" />
<PackageReference Include="xunit" Version="2.4.2" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.5">
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.10.0" />
<PackageReference Include="xunit" Version="2.8.1" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.8.1">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
<PackageReference Include="coverlet.collector" Version="3.2.0">
<PackageReference Include="coverlet.collector" Version="6.0.2">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
Expand Down

0 comments on commit 0a1d577

Please sign in to comment.