Exemple #1
0
        public void Success_LogIn()
        {
            //Arrange
            string     result;
            CustomUser user;

            //Act
            user = new CustomUser
            {
                Username = "******",
                Password = "******",
                Email    = "ClassLibrary1 - Test user database - LogIn",
                IsActive = true,
                Wallet   = 500,
                LoggedIn = false
            };

            result = db_user.CreateUser(user);
            usernames.Add(user.Username);

            if (result.Equals("Success"))
            {
                result = db_user.LogIn(user);
            }

            //Assert
            Assert.AreEqual("Success", result);
        }
 /// <summary>
 /// Log a user in
 /// </summary>
 /// <param name="user"></param>
 public void LogIn(CustomUser user)
 {
     db_user.LogIn(user);
 }