public void Arrange()
 {
     _dataService = new DataService(new CrisisCheckin());
     _dataAccessHelper = new DataAccessHelper(_dataService);
     _clusterCoordinatorService = new ClusterCoordinatorService(_dataService);
     _disaster = _dataAccessHelper.Create_a_disaster();
     _person = _dataAccessHelper.Create_a_volunteer();
     _clusterId = _person.ClusterId.GetValueOrDefault();
 }
 public void Arrange()
 {
     _dataService = new DataService(new CrisisCheckin(), new CrisisCheckinMembership());
     _dataAccessHelper = new DataAccessHelper(_dataService);
     _clusterCoordinatorService = new ClusterCoordinatorService(_dataService);
     _disaster = _dataAccessHelper.Create_a_disaster();
     _clusterId = _dataAccessHelper.GetRandomClusterId();
     _person = _dataAccessHelper.Create_a_volunteer();
 }
 public void Arrange()
 {
     _dataService = new DataService(new CrisisCheckin(), new CrisisCheckinMembership());
     _dataAccessHelper = new DataAccessHelper(_dataService);
     _clusterCoordinatorService = new ClusterCoordinatorService(_dataService);
     var disaster = _dataAccessHelper.Create_a_disaster();
     var person = _dataAccessHelper.Create_a_volunteer();
     var clusterId = person.ClusterId.GetValueOrDefault();
     _clusterCoordinator = _clusterCoordinatorService.AssignClusterCoordinator(disaster.Id, clusterId, person.Id);
 }
Пример #4
0
        public void Arrange()
        {
            // Arrange
            _dataService = new DataService(new CrisisCheckin(), new CrisisCheckinMembership());
            _dataAccessHelper = new DataAccessHelper(_dataService);
            var volunteerService = new VolunteerService(_dataService);
            var previouslyCreatedPerson = _dataAccessHelper.Create_a_volunteer();

            // Act
            var volunteer = volunteerService.FindByUserId(previouslyCreatedPerson.UserId.Value);

            // Assert
            Assert.IsNotNull(volunteer);
            Assert.AreEqual(previouslyCreatedPerson.FirstName, volunteer.FirstName);
        }
 public DataAccessHelper(DataService dataService)
 {
     _dataService = dataService;
 }
 public void Arrange()
 {
     _dataService = new DataService(new CrisisCheckin());
     Create_a_disaster();
     Create_a_person();
 }
Пример #7
0
 public void Arrange()
 {
     _dataService = new DataService(new CrisisCheckin());
     _dataAccessHelper = new DataAccessHelper(_dataService);
     _person = _dataAccessHelper.Create_a_volunteer();
 }