diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index c9dacf911ee5..162d94da6784 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -1,34 +1,34 @@ - + https://github.com/dotnet/installer - 893b762b6e36d558df7ae6fccdfd8034f83a1c2e + c61f05c5628fdba80433184eb00353a908dbdccc https://github.com/dotnet/runtime cf47d9ff6827a3e1d6f2acbf925cd618418f20dd - + https://github.com/dotnet/runtime - 5e603d595e63ddc5cdce9777a40608279abdcc37 + 6b9381be09980dac0d2fc554cf478e054c005cdb - + https://github.com/dotnet/runtime - 5e603d595e63ddc5cdce9777a40608279abdcc37 + 6b9381be09980dac0d2fc554cf478e054c005cdb - + https://github.com/dotnet/aspnetcore - 3e5155276f3d486ef49e1f06ee875d6757983695 + 79ef5e329b1e31c3775a1977798253cc8f7da6cc - + https://github.com/dotnet/emsdk - 0f3e462442af5fe65271e3185d5b645ad40a6041 + 9ad7c262f14dc5e40a64030ade7788b36e74adf0 - + https://github.com/dotnet/cecil - 0d0bc8e0f47fdae9834e1eac678f364c50946133 + 9c8ea966df62f764523b51772763e74e71040a92 diff --git a/eng/Versions.props b/eng/Versions.props index 95a024bc0aa0..df333ff52877 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -2,15 +2,15 @@ - 9.0.100-preview.3.24153.2 - 9.0.0-preview.3.24129.2 + 9.0.100-preview.4.24211.4 + 9.0.0-preview.4.24209.8 9.0.0-alpha.1.23556.4 6.0.0-beta.21212.6 - 9.0.0-preview.3.24129.2 + 9.0.0-preview.4.24209.8 8.0.0-rtm.23511.3 9.0.0-alpha.1.23556.4 7.0.100-alpha.1.21601.1 - 0.11.4-alpha.24120.1 + 0.11.4-alpha.24168.1 9.0.0-prerelease.24203.1 $(MicrosoftNETWorkloadEmscriptenCurrentManifest80100Version) diff --git a/global.json b/global.json index 25d39b4601df..be3417184306 100644 --- a/global.json +++ b/global.json @@ -1,5 +1,5 @@ { "sdk": { - "version": "9.0.100-preview.3.24153.2" + "version": "9.0.100-preview.4.24211.4" } } diff --git a/tests/dotnet/UnitTests/TrimmerWarningsTest.cs b/tests/dotnet/UnitTests/TrimmerWarningsTest.cs index baa7ccdc5c3d..d9ad55b8c9a3 100644 --- a/tests/dotnet/UnitTests/TrimmerWarningsTest.cs +++ b/tests/dotnet/UnitTests/TrimmerWarningsTest.cs @@ -8,7 +8,23 @@ public class TrimmerWarningsTest : TestBaseClass { [TestCase (ApplePlatform.TVOS, "tvossimulator-x64")] public void TrimmerWarningsManagedStaticRegistrar (ApplePlatform platform, string runtimeIdentifiers) { - TrimmerWarnings (platform, runtimeIdentifiers, "managed-static", Array.Empty ()); + // FIXME: dotnet/runtime#100256 + ExpectedBuildMessage [] expectedWarnings; + switch (platform) { + case ApplePlatform.iOS: + case ApplePlatform.TVOS: + expectedWarnings = Array.Empty (); + break; + case ApplePlatform.MacOSX: + case ApplePlatform.MacCatalyst: + expectedWarnings = Array.Empty (); + break; + default: + Assert.Fail ($"Unknown platform: {platform}"); + return; + } + + TrimmerWarnings (platform, runtimeIdentifiers, "managed-static", expectedWarnings); } [Test] @@ -18,7 +34,23 @@ public void TrimmerWarningsManagedStaticRegistrar (ApplePlatform platform, strin [TestCase (ApplePlatform.TVOS, "tvos-arm64")] public void TrimmerWarningsStaticRegistrar (ApplePlatform platform, string runtimeIdentifiers) { - TrimmerWarnings (platform, runtimeIdentifiers, "static", Array.Empty ()); + // FIXME: dotnet/runtime#100256 + ExpectedBuildMessage [] expectedWarnings; + switch (platform) { + case ApplePlatform.iOS: + case ApplePlatform.TVOS: + expectedWarnings = Array.Empty (); + break; + case ApplePlatform.MacOSX: + case ApplePlatform.MacCatalyst: + expectedWarnings = Array.Empty (); + break; + default: + Assert.Fail ($"Unknown platform: {platform}"); + return; + } + + TrimmerWarnings (platform, runtimeIdentifiers, "static", expectedWarnings); } [Test] @@ -28,7 +60,23 @@ public void TrimmerWarningsStaticRegistrar (ApplePlatform platform, string runti [TestCase (ApplePlatform.TVOS, "tvos-arm64")] public void TrimmerWarningsDynamicRegistrar (ApplePlatform platform, string runtimeIdentifiers) { - TrimmerWarnings (platform, runtimeIdentifiers, "dynamic", Array.Empty ()); + // FIXME: dotnet/runtime#100256 + ExpectedBuildMessage [] expectedWarnings; + switch (platform) { + case ApplePlatform.iOS: + case ApplePlatform.TVOS: + expectedWarnings = Array.Empty (); + break; + case ApplePlatform.MacOSX: + case ApplePlatform.MacCatalyst: + expectedWarnings = Array.Empty (); + break; + default: + Assert.Fail ($"Unknown platform: {platform}"); + return; + } + + TrimmerWarnings (platform, runtimeIdentifiers, "dynamic", expectedWarnings); } void TrimmerWarnings (ApplePlatform platform, string runtimeIdentifiers, string registrar, params ExpectedBuildMessage [] expectedWarnings) diff --git a/tests/monotouch-test/Compression/CompressionStreamTest.cs b/tests/monotouch-test/Compression/CompressionStreamTest.cs index 308855141b56..4653d4f837ea 100644 --- a/tests/monotouch-test/Compression/CompressionStreamTest.cs +++ b/tests/monotouch-test/Compression/CompressionStreamTest.cs @@ -101,7 +101,7 @@ public void CheckNullRead () Assert.Ignore ("Requires iOS 9.0+ or macOS 10.11+"); MemoryStream backing = new MemoryStream (compressed_data); DeflateStream decompressing = new DeflateStream (backing, CompressionMode.Decompress, CompressionAlgorithm.Zlib); - Assert.Throws (() => decompressing.Read (null, 0, 20)); + Assert.Throws (() => IgnoreReturnValue (decompressing.Read (null, 0, 20))); } [Test] @@ -112,7 +112,7 @@ public void CheckCompressingRead () byte [] dummy = new byte [20]; MemoryStream backing = new MemoryStream (); DeflateStream compressing = new DeflateStream (backing, CompressionMode.Compress, CompressionAlgorithm.Zlib); - Assert.Throws (() => compressing.Read (dummy, 0, 20)); + Assert.Throws (() => IgnoreReturnValue (compressing.Read (dummy, 0, 20))); } [Test] @@ -123,7 +123,7 @@ public void CheckRangeRead () byte [] dummy = new byte [20]; MemoryStream backing = new MemoryStream (compressed_data); DeflateStream decompressing = new DeflateStream (backing, CompressionMode.Decompress, CompressionAlgorithm.Zlib); - Assert.Throws (() => decompressing.Read (dummy, 10, 20)); + Assert.Throws (() => IgnoreReturnValue (decompressing.Read (dummy, 10, 20))); } [Test] @@ -135,7 +135,7 @@ public void CheckClosedRead () MemoryStream backing = new MemoryStream (compressed_data); DeflateStream decompressing = new DeflateStream (backing, CompressionMode.Decompress, CompressionAlgorithm.Zlib); decompressing.Close (); - Assert.Throws (() => decompressing.Read (dummy, 0, 20)); + Assert.Throws (() => IgnoreReturnValue (decompressing.Read (dummy, 0, 20))); } [Test] @@ -335,7 +335,13 @@ public void Bug19313 () byte [] buffer = new byte [512]; using (var backing = new Bug19313Stream (compressed_data)) using (var decompressing = new DeflateStream (backing, CompressionMode.Decompress, CompressionAlgorithm.Zlib)) - decompressing.Read (buffer, 0, buffer.Length); + IgnoreReturnValue (decompressing.Read (buffer, 0, buffer.Length)); + } + + // Call this with the return value from CompressionStream.Read to avoid: + // error CA2022: Avoid inexact read with 'Compression.CompressionStream.Read(byte[], int, int)' (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2022) + void IgnoreReturnValue (int value) + { } } } diff --git a/tests/msbuild/Xamarin.MacDev.Tests/TargetTests/DetectSigningIdentityTests.cs b/tests/msbuild/Xamarin.MacDev.Tests/TargetTests/DetectSigningIdentityTests.cs index cef3a573fb50..d99e116612e6 100644 --- a/tests/msbuild/Xamarin.MacDev.Tests/TargetTests/DetectSigningIdentityTests.cs +++ b/tests/msbuild/Xamarin.MacDev.Tests/TargetTests/DetectSigningIdentityTests.cs @@ -66,10 +66,26 @@ public void BundleIdentifierInPartialAppManifest () var recordArgs = BinLog.ReadBuildEvents (rv.BinLogPath).ToList (); var taskIndex = recordArgs.FindIndex (v => v is TaskStartedEventArgs tsea && tsea.TaskName == "DetectSigningIdentity"); Assert.That (taskIndex, Is.GreaterThan (0), "Task index"); - var taskParameterIndex = recordArgs.FindIndex (taskIndex + 1, v => v is BuildMessageEventArgs bmea && bmea.Message.StartsWith ("Task Parameter:BundleIdentifier=")); + var taskParameterIndex = recordArgs.FindIndex (taskIndex + 1, v => { + if (!(v is BuildMessageEventArgs bmea)) + return false; + if (bmea.Message.StartsWith ("Task Parameter:BundleIdentifier=")) + return true; + if (bmea.Message.StartsWith ("TaskInput: BundleIdentifier")) + return true; + return false; + }); Assert.That (taskParameterIndex, Is.GreaterThan (0), "Parameter index"); var taskParameter = (BuildMessageEventArgs) recordArgs [taskParameterIndex]; - var bundleIdentifier = taskParameter.Message.Substring ("Task Parameter:BundleIdentifier=".Length); + var taskMessage = taskParameter.Message; + string bundleIdentifier; + if (taskMessage.StartsWith ("Task Parameter:BundleIdentifier=")) { + bundleIdentifier = taskMessage.Substring ("Task Parameter:BundleIdentifier=".Length); + } else if (taskMessage.StartsWith ("TaskInput: BundleIdentifier")) { + bundleIdentifier = taskMessage.Substring ("TaskInput: BundleIdentifier".Length).Trim (); + } else { + bundleIdentifier = "Unhandled task message format."; + } Assert.AreEqual ("com.xamarin.detectsigningidentitytest", bundleIdentifier, "Bundle identifier"); } }