@Test public void approveAssociation() throws Exception { associationOperationsService.approveAssociation(ASS_APPROVE_UNAPPROVE, USER); verify(associationTrackingOperationService, times(1)).update(ASS_APPROVE_UNAPPROVE, USER, "ASSOCIATION_APPROVED"); verify(associationRepository, times(1)).save(ASS_APPROVE_UNAPPROVE); }
public void approveAssociation(Association association, SecureUser user) { associationErrorsChecked(association); association.setSnpApproved(true); association.setLastUpdateDate(new Date()); createAssociationApproveEvent(association, user); associationRepository.save(association); }
AssociationOperationsService { public void approveAssociation(Association association, SecureUser user) { associationErrorsChecked(association); association.setSnpApproved(true); association.setLastUpdateDate(new Date()); createAssociationApproveEvent(association, user); associationRepository.save(association); } }
AssociationOperationsService { public void approveAssociation(Association association, SecureUser user) { associationErrorsChecked(association); association.setSnpApproved(true); association.setLastUpdateDate(new Date()); createAssociationApproveEvent(association, user); associationRepository.save(association); } @Autowired  AssociationOperationsService(SingleSnpMultiSnpAssociationService singleSnpMultiSnpAssociationService,
                                        SnpInteractionAssociationService snpInteractionAssociationService,
                                        AssociationReportRepository associationReportRepository,
                                        AssociationRepository associationRepository,
                                        LocusRepository locusRepository,
                                        MappingService mappingService,
                                        LociAttributesService lociAttributesService,
                                        ValidationService validationService,
                                        AssociationValidationReportService associationValidationReportService,
                                        ErrorCreationService errorCreationService,
                                        @Qualifier("associationTrackingOperationServiceImpl") TrackingOperationService trackingOperationService,
                                        AssociationMappingErrorService associationMappingErrorService); }
AssociationOperationsService { public void approveAssociation(Association association, SecureUser user) { associationErrorsChecked(association); association.setSnpApproved(true); association.setLastUpdateDate(new Date()); createAssociationApproveEvent(association, user); associationRepository.save(association); } @Autowired  AssociationOperationsService(SingleSnpMultiSnpAssociationService singleSnpMultiSnpAssociationService,
                                        SnpInteractionAssociationService snpInteractionAssociationService,
                                        AssociationReportRepository associationReportRepository,
                                        AssociationRepository associationRepository,
                                        LocusRepository locusRepository,
                                        MappingService mappingService,
                                        LociAttributesService lociAttributesService,
                                        ValidationService validationService,
                                        AssociationValidationReportService associationValidationReportService,
                                        ErrorCreationService errorCreationService,
                                        @Qualifier("associationTrackingOperationServiceImpl") TrackingOperationService trackingOperationService,
                                        AssociationMappingErrorService associationMappingErrorService); List<AssociationValidationView> checkSnpAssociationFormErrors(SnpAssociationStandardMultiForm form,
                                                                         String measurementType); List<AssociationValidationView> checkSnpAssociationErrors(Association association,
                                                                         String measurementType); List<AssociationValidationView> checkSnpAssociationInteractionFormErrors(SnpAssociationInteractionForm form,
                                                                                    String measurementType); Collection<AssociationValidationView> saveAssociationCreatedFromForm(Study study,
                                                                                Association association,
                                                                                SecureUser user,
                                                                                String eRelease); Collection<AssociationValidationView> saveEditedAssociationFromForm(Study study,
                                                                               Association association,
                                                                               Long associationId,
                                                                               SecureUser user,
                                                                               String eRelease); Collection<AssociationValidationView> validateAndSaveAssociation(Study study,
                                                                               Association association,
                                                                               SecureUser user,
                                                                               String eRelease); void saveAssociation(Association association, Study study, Collection<ValidationError> errors); void runMapping(Curator curator, Association association, SecureUser user); String determineIfAssociationIsOrType(Association association); SnpAssociationForm generateForm(Association association); MappingDetails createMappingDetails(Association association); LastViewedAssociation getLastViewedAssociation(Long associationId); void approveAssociation(Association association, SecureUser user); void unapproveAssociation(Association association, SecureUser user); void createAssociationCreationEvent(Association association, SecureUser user); void deleteAssocationReport(Long associationReportId); Collection<String> getGenesIds(Collection<Locus> loci); Collection<String> getSpnsName(Collection<SingleNucleotidePolymorphism> snpsList); }
AssociationOperationsService { public void approveAssociation(Association association, SecureUser user) { associationErrorsChecked(association); association.setSnpApproved(true); association.setLastUpdateDate(new Date()); createAssociationApproveEvent(association, user); associationRepository.save(association); } @Autowired  AssociationOperationsService(SingleSnpMultiSnpAssociationService singleSnpMultiSnpAssociationService,
                                        SnpInteractionAssociationService snpInteractionAssociationService,
                                        AssociationReportRepository associationReportRepository,
                                        AssociationRepository associationRepository,
                                        LocusRepository locusRepository,
                                        MappingService mappingService,
                                        LociAttributesService lociAttributesService,
                                        ValidationService validationService,
                                        AssociationValidationReportService associationValidationReportService,
                                        ErrorCreationService errorCreationService,
                                        @Qualifier("associationTrackingOperationServiceImpl") TrackingOperationService trackingOperationService,
                                        AssociationMappingErrorService associationMappingErrorService); List<AssociationValidationView> checkSnpAssociationFormErrors(SnpAssociationStandardMultiForm form,
                                                                         String measurementType); List<AssociationValidationView> checkSnpAssociationErrors(Association association,
                                                                         String measurementType); List<AssociationValidationView> checkSnpAssociationInteractionFormErrors(SnpAssociationInteractionForm form,
                                                                                    String measurementType); Collection<AssociationValidationView> saveAssociationCreatedFromForm(Study study,
                                                                                Association association,
                                                                                SecureUser user,
                                                                                String eRelease); Collection<AssociationValidationView> saveEditedAssociationFromForm(Study study,
                                                                               Association association,
                                                                               Long associationId,
                                                                               SecureUser user,
                                                                               String eRelease); Collection<AssociationValidationView> validateAndSaveAssociation(Study study,
                                                                               Association association,
                                                                               SecureUser user,
                                                                               String eRelease); void saveAssociation(Association association, Study study, Collection<ValidationError> errors); void runMapping(Curator curator, Association association, SecureUser user); String determineIfAssociationIsOrType(Association association); SnpAssociationForm generateForm(Association association); MappingDetails createMappingDetails(Association association); LastViewedAssociation getLastViewedAssociation(Long associationId); void approveAssociation(Association association, SecureUser user); void unapproveAssociation(Association association, SecureUser user); void createAssociationCreationEvent(Association association, SecureUser user); void deleteAssocationReport(Long associationReportId); Collection<String> getGenesIds(Collection<Locus> loci); Collection<String> getSpnsName(Collection<SingleNucleotidePolymorphism> snpsList);  }