public void AddUser() { SqlUserManager sqm = new SqlUserManager(); int PreCount = sqm.Count(); sqm.AddUser("testUser", "password"); int PostCount = sqm.Count(); Assert.AreEqual((PreCount + 1), PostCount); }
public void AddInvaliduser() { SqlUserManager sqm = new SqlUserManager(); int PreCount = sqm.Count(); sqm.AddUser("", "password"); int PostCount = sqm.Count(); Assert.AreEqual(PreCount, PostCount); }
public void DeleteUserByUsername() { SqlUserManager sqm = new SqlUserManager(); sqm.AddUser("deleteTest", "password"); int PreCount = sqm.Count(); sqm.DeleteUserByUsername("deleteTest"); int PostCount = sqm.Count(); Assert.AreEqual(PreCount-1, PostCount); }