diff --git a/src/installer/test/Microsoft.NET.HostModel.Tests/Microsoft.NET.HostModel.Bundle.Tests/BundlerConsistencyTests.cs b/src/installer/test/Microsoft.NET.HostModel.Tests/Microsoft.NET.HostModel.Bundle.Tests/BundlerConsistencyTests.cs index 2e0bda9e45ed32..00f3b1cc843c26 100644 --- a/src/installer/test/Microsoft.NET.HostModel.Tests/Microsoft.NET.HostModel.Bundle.Tests/BundlerConsistencyTests.cs +++ b/src/installer/test/Microsoft.NET.HostModel.Tests/Microsoft.NET.HostModel.Bundle.Tests/BundlerConsistencyTests.cs @@ -143,6 +143,17 @@ public void TestBundlingNativeBinaries(BundleOptions options) bundler.BundleManifest.Contains($"{coreclr}").Should().Be(options.HasFlag(BundleOptions.BundleNativeBinaries)); } + [Fact] + public void TestFileSizes() + { + var fixture = sharedTestState.TestFixture.Copy(); + var bundler = BundleHelper.Bundle(fixture); + var publishPath = BundleHelper.GetPublishPath(fixture); + + bundler.BundleManifest.Files.ForEach(file => + Assert.True(file.Size == new FileInfo(Path.Combine(publishPath, file.RelativePath)).Length)); + } + [Fact] public void TestAssemblyAlignment() {