@Test public final void testSave() { BankBranch expectedResult = getBankBranch(); when(bankBranchRepository.save(any(BankBranch.class))).thenReturn(expectedResult); final BankBranch actualResult = bankBranchService.save(getBankBranch()); assertEquals(expectedResult, actualResult); }
@Transactional public BankBranch save(BankBranch bankBranch) { return bankBranchRepository.save(bankBranch); }
BankBranchService { @Transactional public BankBranch save(BankBranch bankBranch) { return bankBranchRepository.save(bankBranch); } }
BankBranchService { @Transactional public BankBranch save(BankBranch bankBranch) { return bankBranchRepository.save(bankBranch); }  }
BankBranchService { @Transactional public BankBranch save(BankBranch bankBranch) { return bankBranchRepository.save(bankBranch); }  @Transactional List<BankBranch> create(List<BankBranch> bankBranches, BindingResult errors, RequestInfo requestInfo); @Transactional List<BankBranch> update(List<BankBranch> bankBranches, BindingResult errors, RequestInfo requestInfo); List<BankBranch> fetchRelated(List<BankBranch> bankbranches); @Transactional List<BankBranch> update(List<BankBranch> bankbranches, BindingResult errors); Pagination<BankBranch> search(BankBranchSearch bankBranchSearch, BindingResult errors); @Transactional BankBranch save(BankBranch bankBranch); @Transactional BankBranch update(BankBranch bankBranch); }
BankBranchService { @Transactional public BankBranch save(BankBranch bankBranch) { return bankBranchRepository.save(bankBranch); }  @Transactional List<BankBranch> create(List<BankBranch> bankBranches, BindingResult errors, RequestInfo requestInfo); @Transactional List<BankBranch> update(List<BankBranch> bankBranches, BindingResult errors, RequestInfo requestInfo); List<BankBranch> fetchRelated(List<BankBranch> bankbranches); @Transactional List<BankBranch> update(List<BankBranch> bankbranches, BindingResult errors); Pagination<BankBranch> search(BankBranchSearch bankBranchSearch, BindingResult errors); @Transactional BankBranch save(BankBranch bankBranch); @Transactional BankBranch update(BankBranch bankBranch);  }