From 90350e8162874354952364bafe377104966bd977 Mon Sep 17 00:00:00 2001 From: alzimmermsft <48699787+alzimmermsft@users.noreply.github.com> Date: Thu, 14 May 2026 17:12:25 -0400 Subject: [PATCH 1/3] [Part 1] Move tests to unified project design --- Microsoft.Mcp.slnx | 9 ++++----- servers/Azure.Mcp.Server/Azure.Mcp.Server.slnx | 7 +++---- .../src/Properties/AssemblyInfo.cs | 2 +- .../Azure.Mcp.Server.Tests.csproj} | 0 .../Infrastructure/CommandMetadataSyncTests.cs | 2 +- .../Infrastructure/ConsolidatedModeTests.cs | 4 ++-- .../Infrastructure/GetTargetAreaNameTests.cs | 2 +- .../Infrastructure/ServiceRegistrationTests.cs | 2 +- .../Infrastructure/VisualStudioToolNameTests.cs | 2 +- .../Fabric.Mcp.Server/Fabric.Mcp.Server.slnx | 2 +- .../Fabric.Mcp.Server.Tests.csproj} | 0 .../Infrastructure/ServerStartupTests.cs | 2 +- tools/Azure.Mcp.Tools.Acr/src/AssemblyInfo.cs | 3 +-- .../Azure.Mcp.Tools.Acr.LiveTests.csproj | 17 ----------------- .../Azure.Mcp.Tools.Acr.LiveTests/assets.json | 6 ------ .../AcrCommandTests.cs | 7 ++++--- .../AssemblyAttributes.cs | 0 .../Azure.Mcp.Tools.Acr.Tests.csproj} | 0 .../Registry/RegistryListCommandTests.cs | 2 +- .../RegistryRepositoryListCommandTests.cs | 2 +- .../tests/Azure.Mcp.Tools.Acr.Tests/assets.json | 6 ++++++ .../Azure.Mcp.Tools.Advisor/src/AssemblyInfo.cs | 3 +-- .../Azure.Mcp.Tools.Advisor.Tests.csproj} | 0 .../RecommendationListCommandTests.cs | 2 +- 24 files changed, 31 insertions(+), 51 deletions(-) rename servers/Azure.Mcp.Server/tests/{Azure.Mcp.Server.UnitTests/Azure.Mcp.Server.UnitTests.csproj => Azure.Mcp.Server.Tests/Azure.Mcp.Server.Tests.csproj} (100%) rename servers/Azure.Mcp.Server/tests/{Azure.Mcp.Server.UnitTests => Azure.Mcp.Server.Tests}/Infrastructure/CommandMetadataSyncTests.cs (98%) rename servers/Azure.Mcp.Server/tests/{Azure.Mcp.Server.UnitTests => Azure.Mcp.Server.Tests}/Infrastructure/ConsolidatedModeTests.cs (97%) rename servers/Azure.Mcp.Server/tests/{Azure.Mcp.Server.UnitTests => Azure.Mcp.Server.Tests}/Infrastructure/GetTargetAreaNameTests.cs (98%) rename servers/Azure.Mcp.Server/tests/{Azure.Mcp.Server.UnitTests => Azure.Mcp.Server.Tests}/Infrastructure/ServiceRegistrationTests.cs (98%) rename servers/Azure.Mcp.Server/tests/{Azure.Mcp.Server.UnitTests => Azure.Mcp.Server.Tests}/Infrastructure/VisualStudioToolNameTests.cs (98%) rename servers/Fabric.Mcp.Server/tests/{Fabric.Mcp.Server.UnitTests/Fabric.Mcp.Server.UnitTests.csproj => Fabric.Mcp.Server.Tests/Fabric.Mcp.Server.Tests.csproj} (100%) rename servers/Fabric.Mcp.Server/tests/{Fabric.Mcp.Server.UnitTests => Fabric.Mcp.Server.Tests}/Infrastructure/ServerStartupTests.cs (97%) delete mode 100644 tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.LiveTests/Azure.Mcp.Tools.Acr.LiveTests.csproj delete mode 100644 tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.LiveTests/assets.json rename tools/Azure.Mcp.Tools.Acr/tests/{Azure.Mcp.Tools.Acr.LiveTests => Azure.Mcp.Tools.Acr.Tests}/AcrCommandTests.cs (96%) rename tools/Azure.Mcp.Tools.Acr/tests/{Azure.Mcp.Tools.Acr.UnitTests => Azure.Mcp.Tools.Acr.Tests}/AssemblyAttributes.cs (100%) rename tools/Azure.Mcp.Tools.Acr/tests/{Azure.Mcp.Tools.Acr.UnitTests/Azure.Mcp.Tools.Acr.UnitTests.csproj => Azure.Mcp.Tools.Acr.Tests/Azure.Mcp.Tools.Acr.Tests.csproj} (100%) rename tools/Azure.Mcp.Tools.Acr/tests/{Azure.Mcp.Tools.Acr.UnitTests => Azure.Mcp.Tools.Acr.Tests}/Registry/RegistryListCommandTests.cs (98%) rename tools/Azure.Mcp.Tools.Acr/tests/{Azure.Mcp.Tools.Acr.UnitTests => Azure.Mcp.Tools.Acr.Tests}/Registry/RegistryRepositoryListCommandTests.cs (98%) create mode 100644 tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/assets.json rename tools/Azure.Mcp.Tools.Advisor/tests/{Azure.Mcp.Tools.Advisor.UnitTests/Azure.Mcp.Tools.Advisor.UnitTests.csproj => Azure.Mcp.Tools.Advisor.Tests/Azure.Mcp.Tools.Advisor.Tests.csproj} (100%) rename tools/Azure.Mcp.Tools.Advisor/tests/{Azure.Mcp.Tools.Advisor.UnitTests => Azure.Mcp.Tools.Advisor.Tests}/Recommendation/RecommendationListCommandTests.cs (98%) diff --git a/Microsoft.Mcp.slnx b/Microsoft.Mcp.slnx index 405b9c34f8..01d81f228d 100644 --- a/Microsoft.Mcp.slnx +++ b/Microsoft.Mcp.slnx @@ -57,14 +57,14 @@ - + - + @@ -76,15 +76,14 @@ - - + - + diff --git a/servers/Azure.Mcp.Server/Azure.Mcp.Server.slnx b/servers/Azure.Mcp.Server/Azure.Mcp.Server.slnx index b74b5730be..85ffb602f0 100644 --- a/servers/Azure.Mcp.Server/Azure.Mcp.Server.slnx +++ b/servers/Azure.Mcp.Server/Azure.Mcp.Server.slnx @@ -22,7 +22,7 @@ - + @@ -30,15 +30,14 @@ - - + - + diff --git a/servers/Azure.Mcp.Server/src/Properties/AssemblyInfo.cs b/servers/Azure.Mcp.Server/src/Properties/AssemblyInfo.cs index 305ed771c5..ac3708f3da 100644 --- a/servers/Azure.Mcp.Server/src/Properties/AssemblyInfo.cs +++ b/servers/Azure.Mcp.Server/src/Properties/AssemblyInfo.cs @@ -1,2 +1,2 @@ [assembly: System.Runtime.CompilerServices.InternalsVisibleTo("Azure.Mcp.Core.Tests")] -[assembly: System.Runtime.CompilerServices.InternalsVisibleTo("Azure.Mcp.Server.UnitTests")] +[assembly: System.Runtime.CompilerServices.InternalsVisibleTo("Azure.Mcp.Server.Tests")] diff --git a/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.UnitTests/Azure.Mcp.Server.UnitTests.csproj b/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.Tests/Azure.Mcp.Server.Tests.csproj similarity index 100% rename from servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.UnitTests/Azure.Mcp.Server.UnitTests.csproj rename to servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.Tests/Azure.Mcp.Server.Tests.csproj diff --git a/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.UnitTests/Infrastructure/CommandMetadataSyncTests.cs b/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.Tests/Infrastructure/CommandMetadataSyncTests.cs similarity index 98% rename from servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.UnitTests/Infrastructure/CommandMetadataSyncTests.cs rename to servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.Tests/Infrastructure/CommandMetadataSyncTests.cs index f99525ea8f..335e511c5d 100644 --- a/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.UnitTests/Infrastructure/CommandMetadataSyncTests.cs +++ b/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.Tests/Infrastructure/CommandMetadataSyncTests.cs @@ -5,7 +5,7 @@ using Microsoft.Mcp.Core.Services.ProcessExecution; using Xunit; -namespace Azure.Mcp.Server.UnitTests.Infrastructure; +namespace Azure.Mcp.Server.Tests.Infrastructure; public class CommandMetadataSyncTests { diff --git a/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.UnitTests/Infrastructure/ConsolidatedModeTests.cs b/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.Tests/Infrastructure/ConsolidatedModeTests.cs similarity index 97% rename from servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.UnitTests/Infrastructure/ConsolidatedModeTests.cs rename to servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.Tests/Infrastructure/ConsolidatedModeTests.cs index 0a01c27a7c..79ce286b89 100644 --- a/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.UnitTests/Infrastructure/ConsolidatedModeTests.cs +++ b/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.Tests/Infrastructure/ConsolidatedModeTests.cs @@ -3,7 +3,7 @@ using Xunit; -namespace Azure.Mcp.Server.UnitTests.Infrastructure; +namespace Azure.Mcp.Server.Tests.Infrastructure; public class ConsolidatedModeTests { @@ -79,7 +79,7 @@ public async Task ConsolidatedMode_Should_List_Tools_Successfully() } } - private static async Task ReadJsonRpcResponseAsync(System.IO.StreamReader reader) + private static async Task ReadJsonRpcResponseAsync(StreamReader reader) { using var cts = new CancellationTokenSource(TimeSpan.FromSeconds(10)); try diff --git a/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.UnitTests/Infrastructure/GetTargetAreaNameTests.cs b/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.Tests/Infrastructure/GetTargetAreaNameTests.cs similarity index 98% rename from servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.UnitTests/Infrastructure/GetTargetAreaNameTests.cs rename to servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.Tests/Infrastructure/GetTargetAreaNameTests.cs index 7c9d9c93ce..7a4c4d6bed 100644 --- a/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.UnitTests/Infrastructure/GetTargetAreaNameTests.cs +++ b/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.Tests/Infrastructure/GetTargetAreaNameTests.cs @@ -3,7 +3,7 @@ using Xunit; -namespace Azure.Mcp.Server.UnitTests.Infrastructure; +namespace Azure.Mcp.Server.Tests.Infrastructure; public class GetTargetAreaNameTests { diff --git a/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.UnitTests/Infrastructure/ServiceRegistrationTests.cs b/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.Tests/Infrastructure/ServiceRegistrationTests.cs similarity index 98% rename from servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.UnitTests/Infrastructure/ServiceRegistrationTests.cs rename to servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.Tests/Infrastructure/ServiceRegistrationTests.cs index b4af4ad893..8f7bac98a0 100644 --- a/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.UnitTests/Infrastructure/ServiceRegistrationTests.cs +++ b/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.Tests/Infrastructure/ServiceRegistrationTests.cs @@ -5,7 +5,7 @@ using Microsoft.Mcp.Core.Areas.Server.Commands.ServerInstructions; using Xunit; -namespace Azure.Mcp.Server.UnitTests.Infrastructure; +namespace Azure.Mcp.Server.Tests.Infrastructure; public class ServiceRegistrationTests { diff --git a/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.UnitTests/Infrastructure/VisualStudioToolNameTests.cs b/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.Tests/Infrastructure/VisualStudioToolNameTests.cs similarity index 98% rename from servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.UnitTests/Infrastructure/VisualStudioToolNameTests.cs rename to servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.Tests/Infrastructure/VisualStudioToolNameTests.cs index 16050dd7be..99834a5e51 100644 --- a/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.UnitTests/Infrastructure/VisualStudioToolNameTests.cs +++ b/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.Tests/Infrastructure/VisualStudioToolNameTests.cs @@ -14,7 +14,7 @@ using NSubstitute; using Xunit; -namespace Azure.Mcp.Server.UnitTests.Infrastructure; +namespace Azure.Mcp.Server.Tests.Infrastructure; /// /// Tests to ensure specific tool names that Visual Studio depends on remain stable. diff --git a/servers/Fabric.Mcp.Server/Fabric.Mcp.Server.slnx b/servers/Fabric.Mcp.Server/Fabric.Mcp.Server.slnx index 11821aaa94..0125ff29bf 100644 --- a/servers/Fabric.Mcp.Server/Fabric.Mcp.Server.slnx +++ b/servers/Fabric.Mcp.Server/Fabric.Mcp.Server.slnx @@ -18,7 +18,7 @@ - + diff --git a/servers/Fabric.Mcp.Server/tests/Fabric.Mcp.Server.UnitTests/Fabric.Mcp.Server.UnitTests.csproj b/servers/Fabric.Mcp.Server/tests/Fabric.Mcp.Server.Tests/Fabric.Mcp.Server.Tests.csproj similarity index 100% rename from servers/Fabric.Mcp.Server/tests/Fabric.Mcp.Server.UnitTests/Fabric.Mcp.Server.UnitTests.csproj rename to servers/Fabric.Mcp.Server/tests/Fabric.Mcp.Server.Tests/Fabric.Mcp.Server.Tests.csproj diff --git a/servers/Fabric.Mcp.Server/tests/Fabric.Mcp.Server.UnitTests/Infrastructure/ServerStartupTests.cs b/servers/Fabric.Mcp.Server/tests/Fabric.Mcp.Server.Tests/Infrastructure/ServerStartupTests.cs similarity index 97% rename from servers/Fabric.Mcp.Server/tests/Fabric.Mcp.Server.UnitTests/Infrastructure/ServerStartupTests.cs rename to servers/Fabric.Mcp.Server/tests/Fabric.Mcp.Server.Tests/Infrastructure/ServerStartupTests.cs index 0248df82fe..8b5744c278 100644 --- a/servers/Fabric.Mcp.Server/tests/Fabric.Mcp.Server.UnitTests/Infrastructure/ServerStartupTests.cs +++ b/servers/Fabric.Mcp.Server/tests/Fabric.Mcp.Server.Tests/Infrastructure/ServerStartupTests.cs @@ -3,7 +3,7 @@ using Xunit; -namespace Fabric.Mcp.Server.UnitTests.Infrastructure; +namespace Fabric.Mcp.Server.Tests.Infrastructure; public class ServerStartupTests { diff --git a/tools/Azure.Mcp.Tools.Acr/src/AssemblyInfo.cs b/tools/Azure.Mcp.Tools.Acr/src/AssemblyInfo.cs index dca3eb541c..474422442b 100644 --- a/tools/Azure.Mcp.Tools.Acr/src/AssemblyInfo.cs +++ b/tools/Azure.Mcp.Tools.Acr/src/AssemblyInfo.cs @@ -3,5 +3,4 @@ using System.Runtime.CompilerServices; -[assembly: InternalsVisibleTo("Azure.Mcp.Tools.Acr.UnitTests")] -[assembly: InternalsVisibleTo("Azure.Mcp.Tools.Acr.LiveTests")] +[assembly: InternalsVisibleTo("Azure.Mcp.Tools.Acr.Tests")] diff --git a/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.LiveTests/Azure.Mcp.Tools.Acr.LiveTests.csproj b/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.LiveTests/Azure.Mcp.Tools.Acr.LiveTests.csproj deleted file mode 100644 index 0f06a032a0..0000000000 --- a/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.LiveTests/Azure.Mcp.Tools.Acr.LiveTests.csproj +++ /dev/null @@ -1,17 +0,0 @@ - - - true - Exe - - - - - - - - - - - - - diff --git a/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.LiveTests/assets.json b/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.LiveTests/assets.json deleted file mode 100644 index 1ea2dcba56..0000000000 --- a/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.LiveTests/assets.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "AssetsRepo": "Azure/azure-sdk-assets", - "AssetsRepoPrefixPath": "", - "TagPrefix": "Azure.Mcp.Tools.Acr.LiveTests", - "Tag": "Azure.Mcp.Tools.Acr.LiveTests_0941b86ef8" -} diff --git a/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.LiveTests/AcrCommandTests.cs b/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/AcrCommandTests.cs similarity index 96% rename from tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.LiveTests/AcrCommandTests.cs rename to tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/AcrCommandTests.cs index 6566f3f048..19c3bdeaf8 100644 --- a/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.LiveTests/AcrCommandTests.cs +++ b/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/AcrCommandTests.cs @@ -10,9 +10,10 @@ using Microsoft.Mcp.Tests.Helpers; using Xunit; -namespace Azure.Mcp.Tools.Acr.LiveTests; +namespace Azure.Mcp.Tools.Acr.Tests; -public class AcrCommandTests(ITestOutputHelper output, TestProxyFixture fixture, LiveServerFixture liveServerFixture) : RecordedCommandTestsBase(output, fixture, liveServerFixture) +public class AcrCommandTests(ITestOutputHelper output, TestProxyFixture fixture, LiveServerFixture liveServerFixture) + : RecordedCommandTestsBase(output, fixture, liveServerFixture) { public override List DisabledDefaultSanitizers => [ @@ -23,7 +24,7 @@ public class AcrCommandTests(ITestOutputHelper output, TestProxyFixture fixture, public override List BodyKeySanitizers => [ ..base.BodyKeySanitizers, - new BodyKeySanitizer(new BodyKeySanitizerBody("$..data.properties.loginServer") { + new(new("$..data.properties.loginServer") { Value = "sanitized.azurecr.io" }) ]; diff --git a/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.UnitTests/AssemblyAttributes.cs b/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/AssemblyAttributes.cs similarity index 100% rename from tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.UnitTests/AssemblyAttributes.cs rename to tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/AssemblyAttributes.cs diff --git a/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.UnitTests/Azure.Mcp.Tools.Acr.UnitTests.csproj b/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/Azure.Mcp.Tools.Acr.Tests.csproj similarity index 100% rename from tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.UnitTests/Azure.Mcp.Tools.Acr.UnitTests.csproj rename to tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/Azure.Mcp.Tools.Acr.Tests.csproj diff --git a/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.UnitTests/Registry/RegistryListCommandTests.cs b/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/Registry/RegistryListCommandTests.cs similarity index 98% rename from tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.UnitTests/Registry/RegistryListCommandTests.cs rename to tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/Registry/RegistryListCommandTests.cs index 8420ca2866..f25de965aa 100644 --- a/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.UnitTests/Registry/RegistryListCommandTests.cs +++ b/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/Registry/RegistryListCommandTests.cs @@ -14,7 +14,7 @@ using NSubstitute.ExceptionExtensions; using Xunit; -namespace Azure.Mcp.Tools.Acr.UnitTests.Registry; +namespace Azure.Mcp.Tools.Acr.Tests.Registry; public class RegistryListCommandTests : CommandUnitTestsBase { diff --git a/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.UnitTests/Registry/RegistryRepositoryListCommandTests.cs b/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/Registry/RegistryRepositoryListCommandTests.cs similarity index 98% rename from tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.UnitTests/Registry/RegistryRepositoryListCommandTests.cs rename to tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/Registry/RegistryRepositoryListCommandTests.cs index 2cf56a93d0..d4460ba845 100644 --- a/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.UnitTests/Registry/RegistryRepositoryListCommandTests.cs +++ b/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/Registry/RegistryRepositoryListCommandTests.cs @@ -11,7 +11,7 @@ using NSubstitute.ExceptionExtensions; using Xunit; -namespace Azure.Mcp.Tools.Acr.UnitTests.Registry; +namespace Azure.Mcp.Tools.Acr.Tests.Registry; public class RegistryRepositoryListCommandTests : CommandUnitTestsBase { diff --git a/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/assets.json b/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/assets.json new file mode 100644 index 0000000000..ffcd4a5f3b --- /dev/null +++ b/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/assets.json @@ -0,0 +1,6 @@ +{ + "AssetsRepo": "Azure/azure-sdk-assets", + "AssetsRepoPrefixPath": "", + "TagPrefix": "Azure.Mcp.Tools.Acr.Tests", + "Tag": "Azure.Mcp.Tools.Acr.Tests_d98afeda63" +} diff --git a/tools/Azure.Mcp.Tools.Advisor/src/AssemblyInfo.cs b/tools/Azure.Mcp.Tools.Advisor/src/AssemblyInfo.cs index 953c6d9f27..b37b6ffba3 100644 --- a/tools/Azure.Mcp.Tools.Advisor/src/AssemblyInfo.cs +++ b/tools/Azure.Mcp.Tools.Advisor/src/AssemblyInfo.cs @@ -3,5 +3,4 @@ using System.Runtime.CompilerServices; -[assembly: InternalsVisibleTo("Azure.Mcp.Tools.Advisor.UnitTests")] -[assembly: InternalsVisibleTo("Azure.Mcp.Tools.Advisor.LiveTests")] +[assembly: InternalsVisibleTo("Azure.Mcp.Tools.Advisor.Tests")] diff --git a/tools/Azure.Mcp.Tools.Advisor/tests/Azure.Mcp.Tools.Advisor.UnitTests/Azure.Mcp.Tools.Advisor.UnitTests.csproj b/tools/Azure.Mcp.Tools.Advisor/tests/Azure.Mcp.Tools.Advisor.Tests/Azure.Mcp.Tools.Advisor.Tests.csproj similarity index 100% rename from tools/Azure.Mcp.Tools.Advisor/tests/Azure.Mcp.Tools.Advisor.UnitTests/Azure.Mcp.Tools.Advisor.UnitTests.csproj rename to tools/Azure.Mcp.Tools.Advisor/tests/Azure.Mcp.Tools.Advisor.Tests/Azure.Mcp.Tools.Advisor.Tests.csproj diff --git a/tools/Azure.Mcp.Tools.Advisor/tests/Azure.Mcp.Tools.Advisor.UnitTests/Recommendation/RecommendationListCommandTests.cs b/tools/Azure.Mcp.Tools.Advisor/tests/Azure.Mcp.Tools.Advisor.Tests/Recommendation/RecommendationListCommandTests.cs similarity index 98% rename from tools/Azure.Mcp.Tools.Advisor/tests/Azure.Mcp.Tools.Advisor.UnitTests/Recommendation/RecommendationListCommandTests.cs rename to tools/Azure.Mcp.Tools.Advisor/tests/Azure.Mcp.Tools.Advisor.Tests/Recommendation/RecommendationListCommandTests.cs index fd5df36465..c37242d698 100644 --- a/tools/Azure.Mcp.Tools.Advisor/tests/Azure.Mcp.Tools.Advisor.UnitTests/Recommendation/RecommendationListCommandTests.cs +++ b/tools/Azure.Mcp.Tools.Advisor/tests/Azure.Mcp.Tools.Advisor.Tests/Recommendation/RecommendationListCommandTests.cs @@ -12,7 +12,7 @@ using NSubstitute.ExceptionExtensions; using Xunit; -namespace Azure.Mcp.Tools.Advisor.UnitTests.Recommendation; +namespace Azure.Mcp.Tools.Advisor.Tests.Recommendation; public class RecommendationListCommandTests : CommandUnitTestsBase { From f076eb8a2ce5a4937da7c07f6d3a1f3760514d04 Mon Sep 17 00:00:00 2001 From: alzimmermsft <48699787+alzimmermsft@users.noreply.github.com> Date: Mon, 18 May 2026 08:54:28 -0400 Subject: [PATCH 2/3] Add test CSPROJ properties --- .../tests/Azure.Mcp.Server.Tests/Azure.Mcp.Server.Tests.csproj | 2 ++ .../Fabric.Mcp.Server.Tests/Fabric.Mcp.Server.Tests.csproj | 2 ++ .../Azure.Mcp.Tools.Acr.Tests/Azure.Mcp.Tools.Acr.Tests.csproj | 2 ++ .../Azure.Mcp.Tools.Advisor.Tests.csproj | 2 ++ 4 files changed, 8 insertions(+) diff --git a/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.Tests/Azure.Mcp.Server.Tests.csproj b/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.Tests/Azure.Mcp.Server.Tests.csproj index 8d28967fd8..dbacf48c3f 100644 --- a/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.Tests/Azure.Mcp.Server.Tests.csproj +++ b/servers/Azure.Mcp.Server/tests/Azure.Mcp.Server.Tests/Azure.Mcp.Server.Tests.csproj @@ -2,6 +2,8 @@ true Exe + false + true diff --git a/servers/Fabric.Mcp.Server/tests/Fabric.Mcp.Server.Tests/Fabric.Mcp.Server.Tests.csproj b/servers/Fabric.Mcp.Server/tests/Fabric.Mcp.Server.Tests/Fabric.Mcp.Server.Tests.csproj index e89fbccf8e..66d235b17f 100644 --- a/servers/Fabric.Mcp.Server/tests/Fabric.Mcp.Server.Tests/Fabric.Mcp.Server.Tests.csproj +++ b/servers/Fabric.Mcp.Server/tests/Fabric.Mcp.Server.Tests/Fabric.Mcp.Server.Tests.csproj @@ -2,6 +2,8 @@ true Exe + false + true diff --git a/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/Azure.Mcp.Tools.Acr.Tests.csproj b/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/Azure.Mcp.Tools.Acr.Tests.csproj index e136bbc0ed..00414eb63b 100644 --- a/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/Azure.Mcp.Tools.Acr.Tests.csproj +++ b/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/Azure.Mcp.Tools.Acr.Tests.csproj @@ -3,6 +3,8 @@ enable enable false + true + true diff --git a/tools/Azure.Mcp.Tools.Advisor/tests/Azure.Mcp.Tools.Advisor.Tests/Azure.Mcp.Tools.Advisor.Tests.csproj b/tools/Azure.Mcp.Tools.Advisor/tests/Azure.Mcp.Tools.Advisor.Tests/Azure.Mcp.Tools.Advisor.Tests.csproj index 52d2076cd0..060ce0dd29 100644 --- a/tools/Azure.Mcp.Tools.Advisor/tests/Azure.Mcp.Tools.Advisor.Tests/Azure.Mcp.Tools.Advisor.Tests.csproj +++ b/tools/Azure.Mcp.Tools.Advisor/tests/Azure.Mcp.Tools.Advisor.Tests/Azure.Mcp.Tools.Advisor.Tests.csproj @@ -2,6 +2,8 @@ true Exe + false + true From 80d218ab93ff48d1aac952267c8eb9a69078c3d2 Mon Sep 17 00:00:00 2001 From: alzimmermsft <48699787+alzimmermsft@users.noreply.github.com> Date: Mon, 18 May 2026 12:36:38 -0400 Subject: [PATCH 3/3] Fix testing issue --- eng/scripts/Test-Code.ps1 | 2 +- .../Azure.Mcp.Tools.Acr.Tests/Azure.Mcp.Tools.Acr.Tests.csproj | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/eng/scripts/Test-Code.ps1 b/eng/scripts/Test-Code.ps1 index 751e835ceb..0109f09f8c 100755 --- a/eng/scripts/Test-Code.ps1 +++ b/eng/scripts/Test-Code.ps1 @@ -324,7 +324,7 @@ try { $command = "dotnet test $coverageArg $resultsArg $loggerArg" if ($filterArg) { - $command += "--filter `"$filterArg`"" + $command += " --filter `"$filterArg`"" } Invoke-LoggedMsBuildCommand -Command $command -AllowedExitCodes @(0, 1) diff --git a/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/Azure.Mcp.Tools.Acr.Tests.csproj b/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/Azure.Mcp.Tools.Acr.Tests.csproj index 00414eb63b..c86d8d9d13 100644 --- a/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/Azure.Mcp.Tools.Acr.Tests.csproj +++ b/tools/Azure.Mcp.Tools.Acr/tests/Azure.Mcp.Tools.Acr.Tests/Azure.Mcp.Tools.Acr.Tests.csproj @@ -1,5 +1,7 @@ + true + Exe enable enable false @@ -19,6 +21,7 @@ +