Exemplo n.º 1
0
        public void InstanceOk()
        {
            //create an instance of the class we want to create
            clsCustomernkkCollection AllShowings = new clsCustomernkkCollection();

            //test to see that it exists
            Assert.IsNotNull(AllShowings);
        }
Exemplo n.º 2
0
        public void CountPropertyOk()
        {
            //create the instance of the class we want to create
            clsCustomernkkCollection AllShowings = new clsCustomernkkCollection();
            //create some test data to assign to the property
            Int32 SomeCount = 1;

            //assign the data to the property
            AllShowings.Count = SomeCount;
            //test to see that the two values are the same
            Assert.AreEqual(AllShowings.Count, SomeCount);
        }
Exemplo n.º 3
0
        public void AllCustomerOK()
        {
            //create an instance of the class we want to create
            clsCustomernkkCollection Customer = new clsCustomernkkCollection();
            //create some test data to assign to the property
            //in this case the data needs to be a list of objects
            List <clsCustomernkk> TestList = new List <clsCustomernkk>();
            //add an item to the list
            //create the item of the test data
            clsCustomernkk TestItem = new clsCustomernkk();

            //set its properties
            TestItem.CustomerId  = 1;
            TestItem.Name        = "James";
            TestItem.Mobile      = "07896857634";
            TestItem.Email       = "*****@*****.**";
            TestItem.DateOfBirth = "04/01/1990";
            //add the item to the test list
            TestList.Add(TestItem);
            //assign the data to the property
            Customer.AllCustomer = TestList;
            //test to see that the two values are the same
            Assert.AreEqual(Customer.AllCustomer, TestList);
        }