Exemple #1
0
        public void RangeCompareToWithin()
        {
            var range = new DoubleRange(3, 10);
            int value = 5;

            int comp = range.CompareTo(value);

            Assert.AreEqual(0, comp);
        }
Exemple #2
0
        public void RangeCompareToAbove()
        {
            var range = new DoubleRange(3, 10);
            int value = 12;

            int comp = range.CompareTo(value);

            Assert.AreEqual(1, comp);
        }
Exemple #3
0
        public void RangeCompareToBelow()
        {
            var range = new DoubleRange(3, 10);
            int value = 1;

            int comp = range.CompareTo(value);

            Assert.AreEqual(-1, comp);
        }