Skip to content

Commit db7c679

Browse files
committed
[msbuild] Fix building apps with extensions remotely.
Pending: the actual fix. For now this only has a test. Fixes https://devdiv.visualstudio.com/DevDiv/_workitems/edit/2542958.
1 parent af462ff commit db7c679

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

tests/dotnet/UnitTests/ProjectTest.cs

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1853,6 +1853,19 @@ public void KillEverything ()
18531853
[TestCase (ApplePlatform.MacOSX, "osx-x64;osx-arm64", true)]
18541854
// [TestCase ("MacCatalyst", "")] - No extension support yet
18551855
public void BuildProjectsWithExtensions (ApplePlatform platform, string runtimeIdentifier, bool isNativeAot)
1856+
{
1857+
BuildProjectsWithExtensionsImpl (platform, runtimeIdentifier, isNativeAot);
1858+
}
1859+
1860+
[TestCase (ApplePlatform.iOS, "ios-arm64", false)]
1861+
[Category ("RemoteWindows")]
1862+
public void BuildProjectsWithExtensionsOnRemoteWindows (ApplePlatform platform, string runtimeIdentifier, bool isNativeAot)
1863+
{
1864+
Configuration.IgnoreIfNotOnWindows ();
1865+
BuildProjectsWithExtensionsImpl (platform, runtimeIdentifier, isNativeAot, AddRemoteProperties ());
1866+
}
1867+
1868+
void BuildProjectsWithExtensionsImpl (ApplePlatform platform, string runtimeIdentifier, bool isNativeAot, Dictionary<string, string>? properties = null)
18561869
{
18571870
Configuration.IgnoreIfIgnoredPlatform (platform);
18581871
var consumingProjectDir = GetProjectPath ("ExtensionConsumer", runtimeIdentifier, platform, out var appPath);
@@ -1861,7 +1874,7 @@ public void BuildProjectsWithExtensions (ApplePlatform platform, string runtimeI
18611874
Clean (extensionProjectDir);
18621875
Clean (consumingProjectDir);
18631876

1864-
var properties = GetDefaultProperties (runtimeIdentifier);
1877+
properties = GetDefaultProperties (runtimeIdentifier, extraProperties: properties);
18651878

18661879
if (isNativeAot) {
18671880
properties ["PublishAot"] = "true";

0 commit comments

Comments
 (0)