diff --git a/czishrink/Directory.Build.props b/czishrink/Directory.Build.props index 611d8b2..dbf09fd 100644 --- a/czishrink/Directory.Build.props +++ b/czishrink/Directory.Build.props @@ -17,6 +17,6 @@ false - 1.1.5 + 1.1.6 diff --git a/czishrink/netczicompressTests/ViewModels/AggregateStatisticsViewModelTests.cs b/czishrink/netczicompressTests/ViewModels/AggregateStatisticsViewModelTests.cs index b0630e9..af473e5 100644 --- a/czishrink/netczicompressTests/ViewModels/AggregateStatisticsViewModelTests.cs +++ b/czishrink/netczicompressTests/ViewModels/AggregateStatisticsViewModelTests.cs @@ -7,6 +7,7 @@ namespace netczicompressTests.ViewModels; using System.ComponentModel; using netczicompress.ViewModels; +using netczicompress.ViewModels.Formatters; /// /// Tests for . @@ -23,7 +24,7 @@ public void Properties_AfterCreation_HaveExpectedValues() var sut = fixture.Create(); // ASSERT - sut.Should().BeEquivalentTo(AggregateStatistics.Empty, options => options.Excluding(o => o.Duration)); + sut.Should().BeEquivalentTo(AggregateStatistics.Empty); } [Fact] @@ -48,7 +49,7 @@ public void OnNext_WhenCalled_ChangesPropertyValues() Times.Once); propertyListener.VerifyNoOtherCalls(); - sut.Should().BeEquivalentTo(newValue, options => options.Excluding(o => o.Duration)); + sut.Should().BeEquivalentTo(newValue); } [Fact] @@ -81,8 +82,15 @@ private static void WhenCalled_DoesNotDoAnything(Action>(); + timeSpanFormatterMock + .Setup(x => x.FormatTimeSpan(It.IsAny())) + .Returns(string.Empty); + var oldValue = fixture.Create(); var sut = fixture.Create(); + sut.OnNext(oldValue); // ACT @@ -92,8 +100,8 @@ private static void WhenCalled_DoesNotDoAnything(Action - sut.Should().BeEquivalentTo(oldValue, options => options.Excluding(o => o.Duration)); + sut.Should().BeEquivalentTo(oldValue); + sut.FormattedDuration.Should().BeEquivalentTo(string.Empty); } private static IFixture CreateFixture()