public void ToByte() { var converter = ConverterFactory.Create <decimal, byte>(); Assert.Equal(ManualConverter.DecimalToByte(0m), converter(0m)); Assert.Equal(ManualConverter.DecimalToByte(1m), converter(1m)); //Assert.Equal(ManualConverter.DecimalToByte(-1m), converter(-1m)); //Assert.Equal(ManualConverter.DecimalToByte(Decimal.MinValue), converter(Decimal.MinValue)); //Assert.Equal(ManualConverter.DecimalToByte(Decimal.MaxValue), converter(Decimal.MaxValue)); }