Ejemplo n.º 1
0
        public void SimpleListToSimpleListViewModelTest()
        {
            Mapper target = new Mapper();                                           // TODO: Initialize to an appropriate value

            Infostructure.SimpleList.DataModel.Models.SimpleList simpleList = null; // TODO: Initialize to an appropriate value
            bool populateSubStructures   = false;                                   // TODO: Initialize to an appropriate value
            SimpleListViewModel expected = null;                                    // TODO: Initialize to an appropriate value
            SimpleListViewModel actual;

            actual = target.SimpleListToSimpleListViewModel(simpleList, populateSubStructures);
            Assert.AreEqual(expected, actual);
            Assert.Inconclusive("Verify the correctness of this test method.");
        }
 public void SetUp()
 {
     _simpleListToTest = new DataModel.Models.SimpleList
     {
         ID              = 0,
         Name            = "test list 1",
         DateAdded       = DateTime.Now,
         AllDone         = false,
         UserID          = 1,
         SimpleListItems = new System.Collections.Generic.List <Infostructure.SimpleList.DataModel.Models.SimpleListItem>
         {
             new Infostructure.SimpleList.DataModel.Models.SimpleListItem
             {
                 Description  = "test list 1, descr 1",
                 Done         = true,
                 ID           = 1234,
                 SimpleListID = 0
             },
             new Infostructure.SimpleList.DataModel.Models.SimpleListItem
             {
                 Description  = "test list 1, descr 2",
                 Done         = false,
                 ID           = 12345,
                 SimpleListID = 0
             },
             new Infostructure.SimpleList.DataModel.Models.SimpleListItem
             {
                 Description  = "test list 1, descr 3",
                 Done         = false,
                 ID           = 123456,
                 SimpleListID = 0
             }
         }
     };
     _userForTest = new User
     {
         ID                = 1,
         Email             = "*****@*****.**",
         Name              = "Bernard",
         Password          = "******",
         ShowDoneListItems = false,
         ShowDoneLists     = false,
         SimpleLists       = null
     };
 }
 public void CloneDoneTest()
 {
     Infostructure.SimpleList.DataModel.Models.SimpleList simpleListClonedDone = _simpleListToTest.Clone(_userForTest.ID, false, "cloned list 2");
     Assert.AreEqual(simpleListClonedDone.SimpleListItems.Count, 2);
     Assert.AreEqual(simpleListClonedDone.Name, "cloned list 2");
 }
 public void CloneAllTest()
 {
     Infostructure.SimpleList.DataModel.Models.SimpleList simpleListClonedAll = _simpleListToTest.Clone(_userForTest.ID, true, "cloned list 1");
     Assert.AreEqual(simpleListClonedAll.SimpleListItems.Count, 3);
     Assert.AreEqual(simpleListClonedAll.Name, "cloned list 1");
 }