public void ReadXElement_SetTimeOfDay_ReturnsCorrectTimeOfDay()
        {
            var frec = new DailyFrecuencyOneTimePerDay();
            frec.TimeOfDay = new TimeSpan(12, 13, 14);

            var element = frec.GetXElement();

            var newFrec = new DailyFrecuencyOneTimePerDay();
            newFrec.ReadXElement(element);

            Assert.IsTrue(frec.TimeOfDay == newFrec.TimeOfDay);
        }
        public void GetXElement_SetTimeOfDay_ReturnsCorrectXml()
        {
            var frec = new DailyFrecuencyOneTimePerDay();
            frec.TimeOfDay = new TimeSpan(12, 13, 14);

            var element = frec.GetXElement();

            var attribute = element.Attribute(DailyFrecuencyOneTimePerDay.CN_TIME_OF_DAY);

            Assert.IsNotNull(attribute);
            Assert.IsTrue(frec.TimeOfDay == TimeSpan.FromTicks(long.Parse(attribute.Value)));
        }