コード例 #1
0
        public void GiftGuideEpochNullTest()
        {
            GiftGuide giftGuide = new GiftGuide();
            giftGuide.CreationEpoch = null;

            Assert.IsFalse(giftGuide.CreationDate.HasValue);
        }
コード例 #2
0
        public void GiftGuideDatesNullByDefaultTest()
        {
            GiftGuide giftGuide = new GiftGuide();

            Assert.IsFalse(giftGuide.CreationEpoch.HasValue);
            Assert.IsFalse(giftGuide.CreationDate.HasValue);
        }
コード例 #3
0
        public void GiftGuideCreationEpochTest()
        {
            GiftGuide giftGuide = new GiftGuide();
            giftGuide.CreationEpoch = 1;

            Assert.AreEqual(1, giftGuide.CreationEpoch);
            Helper.AssertDateIs(giftGuide.CreationDate.Value, 1970, 1, 1, 0, 0, 1);
        }
コード例 #4
0
        public void GiftGuideCreationDateTest()
        {
            GiftGuide giftGuide = new GiftGuide();
            giftGuide.CreationDate = new DateTime(1970, 1, 1);

            Assert.AreEqual(new DateTime(1970, 1, 1), giftGuide.CreationDate);
            Assert.AreEqual(0, giftGuide.CreationEpoch);
        }
コード例 #5
0
        public void GiftGuideViewModelCreateTest()
        {
            GiftGuide giftGuide = new GiftGuide();
            GiftGuideViewModel giftGuideViewModel = new GiftGuideViewModel(giftGuide);

            Assert.IsNotNull(giftGuideViewModel);
            Assert.IsNotNull(giftGuideViewModel.GiftGuide);
        }
コード例 #6
0
 public void GiftGuideSimpleCreateTest()
 {
     GiftGuide giftGuide = new GiftGuide();
     Assert.IsNotNull(giftGuide);
 }
コード例 #7
0
 /// <summary>
 /// Initializes a new instance of the GiftGuideViewModel class
 /// </summary>
 /// <param name="giftGuide">the gift guide Data transfer object</param>
 public GiftGuideViewModel(GiftGuide giftGuide)
 {
     this.giftGuide = giftGuide;
 }