public void SetUp() { _mapper = DtoMappings.GetMapperConfiguration().CreateMapper(); _planRepository = new PlanRepository(_connection, _mapper); _patrolRepository = new PatrolRepository(_connection); _userRepository = new UserRepository(_connection); _user = _userRepository.GetUser(1).Result; _patrol = _patrolRepository.GetPatrolsForUser(_user.Id).Result.First(x => x.Name == "Big Mountain Patrol"); _plan = _planRepository.GetPlansForPatrol(_patrol.Id).Result.First(x => x.Name == "Ski Alpine"); }
public void SetUp() { _patrolRepository = new PatrolRepository(_connection); _user = new User() { Email = "*****@*****.**", PasswordHash = new byte[32], PasswordSalt = new byte[32], PasswordHashIterations = 5, FirstName = "Test", LastName = "Test" }; _user.Id = (int)_connection.Insert(_user); _patrol = new Amphibian.Patrol.Api.Models.Patrol() { Name = "Test", TimeZone = "Eastern Standard Time" }; }