Beispiel #1
0
        public void TestLoginAndAccountCreation()
        {
            Assert.IsTrue(_logic.SetAccount(_account));

            Assert.IsTrue(_logic.CheckLogin(_account), "Tesdata is logged in");

            Assert.IsFalse(_logic.CheckUsername(_account.UserName));
        }
Beispiel #2
0
        public IActionResult LogIn(string userName, string password)
        {
            var account = new Account(userName, password, password);

            if (_accountLogic.CheckAccount(account))
            {
                _accountLogic.CheckLogin(account);
            }
            return(RedirectToAction("Index", "Home"));
        }