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 5, 2024
1 parent a7dabc0 commit ddc632f
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 ddc632f

Please sign in to comment.