Skip to content

Commit

Permalink
Add DesignTimeBuild Performance test
Browse files Browse the repository at this point in the history
  • Loading branch information
dellis1972 committed Dec 9, 2024
1 parent deb85cc commit 60141c1
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
21 changes: 21 additions & 0 deletions tests/MSBuildDeviceIntegration/Tests/PerformanceTest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -395,5 +395,26 @@ public void Install_CSharp_FromClean ()
});
}
}

[Test]
public void DesignTimeBuild_CSharp_From_Clean ()
{
AssertCommercialBuild (); // This test will fail without Fast Deployment

var proj = CreateApplicationProject ();
proj.PackageName = "com.xamarin.designtimebuild_csharp_from_clean";
proj.PackageReferences.Add (KnownPackages.AndroidXAppCompat);
proj.MainActivity = proj.DefaultMainActivity;
using (var builder = CreateBuilderWithoutLogFile ()) {
builder.BuildLogFile = "designtimebuild.log";
builder.Verbosity = LoggerVerbosity.Quiet;
builder.Clean (proj);
builder.Restore (proj);
builder.AutomaticNuGetRestore = false;
Profile (builder, b => {
b.DesignTimeBuild (proj, "CoreCompile", parameters: new string[] { "BuildingInsideVisualStudio=true" });
});
}
}
}
}
1 change: 1 addition & 0 deletions tests/msbuild-times-reference/MSBuildDeviceIntegration.csv
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,4 @@ Install_CSharp_Change,4000
Install_XAML_Change,3750
Install_CSharp_FromClean,3000
Install_CSharp_FromClean,20000
DesignTimeBuild_CSharp_From_Clean,4000

0 comments on commit 60141c1

Please sign in to comment.