public void TestMethod1()
        {
            Mock <CheckEmployee> chk = new Mock <CheckEmployee>();

            chk.Setup(x => x.checkEmp()).Returns(true);

            ProcessEmployee peObj = new ProcessEmployee();

            Assert.AreEqual(peObj.insertEmployee(chk.Object), true);
        }
Exemplo n.º 2
0
        public void TestNethodUsingMOQ()
        {
            Mock <CheckEmployee> chk = new Mock <CheckEmployee>();

            chk.Setup(x => x.CheckEmp()).Returns(true);

            ProcessEmployee obje = new ProcessEmployee();

            Assert.AreEqual(obje.InsertEmployee(chk.Object), true);
        }