示例#1
0
        public void Zero()
        {
            OrdinalFilter of      = new OrdinalFilter();
            String        zeroStr = of.GenerateTextFromNumber(0);

            Assert.AreEqual(zeroStr, "0th");
        }
示例#2
0
        public void Negative()
        {
            OrdinalFilter of  = new OrdinalFilter();
            String        str = of.GenerateTextFromNumber(-1);

            Assert.AreEqual(str, "-1");
        }
示例#3
0
        public void Decimal()
        {
            OrdinalFilter of  = new OrdinalFilter();
            String        str = of.GenerateTextFromNumber(0.5f);

            Assert.AreEqual(str, "0.5");
        }
示例#4
0
        public void ThreeAsFloat()
        {
            OrdinalFilter of  = new OrdinalFilter();
            String        str = of.GenerateTextFromNumber(3.0f);

            Assert.AreEqual(str, "third");
        }
示例#5
0
        public void Five()
        {
            OrdinalFilter of  = new OrdinalFilter();
            String        str = of.GenerateTextFromNumber(5);

            Assert.AreEqual(str, "fifth");
        }
示例#6
0
        public void Ten()
        {
            OrdinalFilter of  = new OrdinalFilter();
            String        str = of.GenerateTextFromNumber(10);

            Assert.AreEqual(str, "10th");
        }
示例#7
0
        public void Nine()
        {
            OrdinalFilter of  = new OrdinalFilter();
            String        str = of.GenerateTextFromNumber(9);

            Assert.AreEqual(str, "ninth");
        }
示例#8
0
        public void Large()
        {
            OrdinalFilter of  = new OrdinalFilter();
            String        str = of.GenerateTextFromNumber(10001);

            Assert.AreEqual(str, "10001st");
        }