FossologyHandler implements FossologyService.Iface { @Override public RequestStatus deployScripts() throws TException { return fossologyScriptsHandler.deployScripts(); } @Autowired  FossologyHandler(FossologyFileHandler fossologyFileHandler, FossologyHostKeyHandler fossologyHostKeyHandler, FossologySshConnector fossologySshConnector, FossologyScriptsHandler fossologyScriptsHandler, FossologySettings fossologySettings); @Override RequestStatus sendToFossology(String releaseId, User user, String clearingTeam); @Override RequestStatus sendReleasesToFossology(List<String> releaseIds, User user, String clearingTeam); @Override Release getStatusInFossology(String releaseId, User user, String clearingTeam); @Override List<FossologyHostFingerPrint> getFingerPrints(); @Override RequestStatus setFingerPrints(List<FossologyHostFingerPrint> fingerPrints); @Override RequestStatus deployScripts(); @Override RequestStatus checkConnection(); @Override String getPublicKey();  }
@Test public void testDeployScripts() throws Exception { final RequestStatus requestStatus = RequestStatus.FAILURE; doReturn(requestStatus).when(fossologyScriptsHandler).deployScripts(); assertThat(fossologyHandler.deployScripts(), sameInstance(requestStatus)); verify(fossologyScriptsHandler).deployScripts(); }