use of org.kie.workbench.common.services.backend.compiler.offprocess.service.impl.CompilerOffprocessServiceImpl in project kie-wb-common by kiegroup.
the class CompilerOffProcessServiceTest method offProcessServiceCompileAsyncTest.
@Test
@Ignore("https://issues.redhat.com/browse/AF-2892")
public void offProcessServiceCompileAsyncTest() throws Exception {
CompilerOffprocessService service = new CompilerOffprocessServiceImpl(executor, queueProvider);
WorkspaceCompilationInfo info = new WorkspaceCompilationInfo(prjPath);
String uuid = UUID.randomUUID().toString();
CompilationRequest req = new DefaultCompilationRequest(mavenRepo, info, new String[] { MavenCLIArgs.COMPILE, MavenCLIArgs.ALTERNATE_USER_SETTINGS + alternateSettingsAbsPath }, Boolean.FALSE, uuid);
CompletableFuture<KieCompilationResponse> futureRes = service.compile(req);
logger.info("offProcessOneBuildAsyncTest build completed");
KieCompilationResponse res = futureRes.get();
assertThat(res).isNotNull();
assertThat(res.isSuccessful()).isTrue();
assertThat(res.getMavenOutput()).isNotEmpty();
DefaultKieCompilationResponse kres = (DefaultKieCompilationResponse) res;
assertThat(uuid).isEqualToIgnoringCase(kres.getRequestUUID());
}
Aggregations