From 9a065d6bbaf71db75e55e142033098f20a8118c1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Per=20Bornsj=C3=B6?= Date: Tue, 25 Apr 2023 22:10:30 +0200 Subject: [PATCH] Fixed swaped arguments --- src/common.tests/FixedSizeStringBuilderTests.cs | 4 ++-- src/library.tests/PortMappingManagerTest.cs | 4 ++-- .../RemoteContainerConnectionDetailsResolverTests.cs | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/common.tests/FixedSizeStringBuilderTests.cs b/src/common.tests/FixedSizeStringBuilderTests.cs index e086ab0a..bdefc148 100644 --- a/src/common.tests/FixedSizeStringBuilderTests.cs +++ b/src/common.tests/FixedSizeStringBuilderTests.cs @@ -31,7 +31,7 @@ public void AppendLong() sb.AppendLine("12345"); sb.Append("678910"); - Assert.Equal(sb.ToString(), "...678910"); + Assert.Equal("...678910", sb.ToString()); Assert.True(sb.MaxLengthReached); } @@ -42,7 +42,7 @@ public void AppendLongValue() sb.Append("12345678910"); - Assert.Equal(sb.ToString(), "...2345678910"); + Assert.Equal("...2345678910", sb.ToString()); Assert.True(sb.MaxLengthReached); } diff --git a/src/library.tests/PortMappingManagerTest.cs b/src/library.tests/PortMappingManagerTest.cs index 41eadf4d..0169a203 100644 --- a/src/library.tests/PortMappingManagerTest.cs +++ b/src/library.tests/PortMappingManagerTest.cs @@ -51,8 +51,8 @@ public async void GetRemoteToFreeLocalPortMappings_HeadlessService(int numServic var assignedPorts = new HashSet(); foreach (var endpoint in endpoints) { foreach (var port in endpoint.Ports) { - Assert.NotEqual(port.LocalPort, -1); - Assert.False(assignedPorts.Contains(port.LocalPort)); + Assert.NotEqual(-1, port.LocalPort); + Assert.DoesNotContain(port.LocalPort, assignedPorts); assignedPorts.Add(port.LocalPort); } } diff --git a/src/library.tests/RemoteContainerConnectionDetailsResolverTests.cs b/src/library.tests/RemoteContainerConnectionDetailsResolverTests.cs index d97fa66e..3cdf7661 100644 --- a/src/library.tests/RemoteContainerConnectionDetailsResolverTests.cs +++ b/src/library.tests/RemoteContainerConnectionDetailsResolverTests.cs @@ -48,7 +48,7 @@ public async void ResolveConnectionDetails_RestoreCheck(int numServices, bool ha // We only care about this exception for this UT. ResolveConnectionDetails is large function and ot get to pass cleanly would require a lot longer set up, // which is not needed for this UT if (e.Message.StartsWith("Restoration pod is still present for the specified service")) { - Assert.Equal(phase, "Running"); + Assert.Equal("Running", phase); Assert.True(hasRestore); } }