Exemplo n.º 1
0
        public void AssertDefaultAthleteForNewUser()
        {
            var userDataAccess = new UserDataAccess();
            MemoryDataContext.Clear();
            const string email = "*****@*****.**";
            const string password = "******";

            var user = userDataAccess.CreateUserWithDefaultAthlete(email, password);

            var athleteDataAccess = new AthleteDataAccess();
            var athlete = athleteDataAccess.GetAthlete(user);
            Assert.AreEqual(user, athlete.User);
        }
Exemplo n.º 2
0
        public void AssertUserDataIsSet()
        {
            var userDataAccess = new UserDataAccess();
            MemoryDataContext.Clear();
            const string email = "*****@*****.**";
            const string password = "******";

            var user = userDataAccess.CreateUserWithDefaultAthlete(email, password);

            Assert.AreEqual(email, user.UserName);
            Assert.AreEqual(password, user.Password);
            Assert.AreEqual(3, MemoryDataContext.CommitCallCount);
            Assert.AreEqual(user.CustomerID, user.ID.ToString());
        }
Exemplo n.º 3
0
 public SecurityService()
 {
     _dataAccess = new UserDataAccess();
 }
Exemplo n.º 4
0
 public SecurityHandler()
 {
     _userDataAccess = new UserDataAccess();
 }