public bool New(string teamName, string longName, IEnumerable<string> teamMembers, string password) { var members = teamMembers.Select(x => new TeamMember(x)); Team team; try { team = new Team(teamName, longName, members, GetMd5HashOf(password)); } catch (ArgumentException e) { return false; } _repository.Add(team); return true; }
public void Update(Team team) { _repository.Update(team); }
protected static void SetupTeamInRepositoryNamed(string name) { var team = new Team(name, name, new TeamMember[0], name); teamRepository = MockRepository.GenerateMock<ITeamRepository>(); teamRepository.Stub(x => x.FindByTeamName(name)).Return(team); }
public void Add(Team team) { _repository.Add(team); }