public void ManageEmployeesTestValid()
        {
            var employee = new Employee
            {
                Username = "",
                Password = ""
            };
            var employeeDal = new MockEmployeeDal()
            {
                AuthenticateValueToReturn = 1,
                ThrowError = false
            };
            var controller = new ManageStaffController(employeeDal);
            var result     = (ViewResult)controller.ManageEmployees();

            Assert.IsInstanceOfType(result, typeof(ViewResult));
            Assert.AreEqual(null, result.ViewName);
            var employees = (List <Employee>)result.Model;

            Assert.AreEqual(0, employees.Count);
        }
        public void ManageEmployeesTestExceptionThrown()
        {
            var employee = new Employee
            {
                Username = "",
                Password = ""
            };
            var employeeDal = new MockEmployeeDal()
            {
                AuthenticateValueToReturn = 1,
                ThrowError = true
            };
            var controller = new ManageStaffController(employeeDal);
            var result     = (ViewResult)controller.ManageEmployees();

            Assert.IsInstanceOfType(result, typeof(ViewResult));
            Assert.AreEqual(null, result.ViewName);
            Assert.AreEqual("Uh-oh something went wrong", result.ViewData["ErrorMessage"]);
            var employees = (List <Employee>)result.Model;

            Assert.AreEqual(0, employees.Count);
        }