Esempio n. 1
0
        public string AddLandlord(MdlLandlord mdlLandlordObj)
        {
            ctrLandlordObj = new CtrLandlord();

            Console.WriteLine();
            Console.WriteLine("AddLandlord() " + GetExecutionThreadTime());

            return ctrLandlordObj.AddLandlord(mdlLandlordObj);
        }
Esempio n. 2
0
        public void AddNewLandlord()
        {
            CtrLandlord ctrLandlordObj = new CtrLandlord();
            MdlLandlord mdlLandlordObj = GenerateLandlordObj();
            string expected = "Registration successful.";
            string actual;

            actual = ctrLandlordObj.AddLandlord(mdlLandlordObj).Trim();
            Assert.AreEqual(expected, actual);
        }
Esempio n. 3
0
        public void AddExistingLandlord()
        {
            CtrLandlord ctrLandlordObj = new CtrLandlord();
            MdlLandlord mdlLandlordObj = GenerateLandlordObj();
            mdlLandlordObj.Email = "*****@*****.**";
            string expected = "Registration has failed due to the existing Email.";
            string actual;

            actual = ctrLandlordObj.AddLandlord(mdlLandlordObj).Trim();
            Assert.AreEqual(expected, actual);
        }
Esempio n. 4
0
 public void CheckEmailTest()
 {
     CtrLandlord ctrLandlord = new CtrLandlord();
     //should return true
     Assert.IsTrue(ctrLandlord.AddLandlord("*****@*****.**", "pass", true, DateTime.Now, "Miro", "Pakanec", "xxx", "f**k", "aalborg", "Denmark", "4546456465"));
 }