Exemple #1
0
        public void DisplayStringContainsAmount()
        {
            var volume = VolumeFactory.Teaspoons(1m);

            Assert.IsTrue(volume.DisplayString.StartsWith("1"));
        }
Exemple #2
0
        public void ToGallons()
        {
            var volume = VolumeFactory.Teaspoons(192m);

            Assert.IsTrue(volume.ToGallons() == 0.25m);
        }
Exemple #3
0
        public void PluralStringFalse()
        {
            var volume = VolumeFactory.Teaspoons(1m);

            Assert.IsFalse(volume.DisplayString.EndsWith("s"));
        }
Exemple #4
0
 private IVolume GetVolume(decimal value)
 {
     return(VolumeFactory.Teaspoons(value));
 }