Ejemplo n.º 1
0
        public void testSetGregorian_3args()
        {
            int        day      = 20;
            int        month    = 12;
            int        year     = 1980;
            GEDCOMDate instance = new GEDCOMDate(null, null, "", "");

            instance.SetGregorian(day, month, year);
            string result = instance.GetDisplayString(DateFormat.dfYYYY_MM_DD, false, false);

            Assert.AreEqual("1980.12.20", result);
        }
Ejemplo n.º 2
0
        public void testSetGregorian_5argsBC()
        {
            int        day          = 20;
            string     month        = "Dec";
            int        year         = 1980;
            string     yearModifier = "";
            bool       yearBC       = true;
            GEDCOMDate instance     = new GEDCOMDate(null, null, "", "");

            instance.SetGregorian(day, month, year, yearModifier, yearBC);
            string result = instance.GetDisplayString(DateFormat.dfYYYY_MM_DD, true, false);

            Assert.AreEqual("BC 1980.12.20", result);
        }