public void GivenAStringWithTrailingZero_WhenParsed_ThenTrailingZeroShouldBePreserved() { string expected = "0.010"; NumberSearchValue value = NumberSearchValue.Parse(expected); Assert.NotNull(value); Assert.Equal(0.010m, value.Number); Assert.Equal(expected, value.ToString()); }
public void GivenASearchValueWithUnequalLowAndHighValues_WhenToStringIsCalled_ThenCorrectStringShouldBeReturned() { NumberSearchValue value = new NumberSearchValue(23.56m, 27); Assert.Equal("[23.56, 27)", value.ToString()); }
public void GivenASearchValue_WhenToStringIsCalled_ThenCorrectStringShouldBeReturned() { NumberSearchValue value = new NumberSearchValue(23.56m); Assert.Equal("23.56", value.ToString()); }