Remove ActiveIssue on OSVersion_ValidVersion_OSX (#70367)
authorEric Erhardt <eric.erhardt@microsoft.com>
Wed, 8 Jun 2022 16:19:04 +0000 (11:19 -0500)
committerGitHub <noreply@github.com>
Wed, 8 Jun 2022 16:19:04 +0000 (10:19 -0600)
* Remove ActiveIssue on OSVersion_ValidVersion_OSX

This test was fixed to work correctly on the latest macOS versions in https://github.com/dotnet/runtime/pull/64565. The test can now be re-enabled.

Fix #49106

* Verify the Minor version as well, since it is no longer being verified by the RID.

src/libraries/System.Runtime.Extensions/tests/System/EnvironmentTests.cs

index 7ec5085..45833c0 100644 (file)
@@ -184,7 +184,6 @@ namespace System.Tests
 
         [Fact]
         [PlatformSpecific(TestPlatforms.OSX)]
-        [ActiveIssue("https://github.com/dotnet/runtime/issues/49106", typeof(PlatformDetection), nameof(PlatformDetection.IsMacOsAppleSilicon))]
         public void OSVersion_ValidVersion_OSX()
         {
             Version version = Environment.OSVersion.Version;
@@ -193,6 +192,7 @@ namespace System.Tests
             // As of 12.0, only major version numbers are included in the RID
             Assert.Contains(version.ToString(1), RuntimeInformation.RuntimeIdentifier);
 
+            Assert.True(version.Minor >= 0, "OSVersion Minor should be non-negative");
             Assert.True(version.Build >= 0, "OSVersion Build should be non-negative");
             Assert.Equal(-1, version.Revision); // Revision is never set on OSX
         }