06-09-2011 12:32 PM
@Test
@Deployment(resources = {"/diagrams/ControlloCrediti.GestioneSolleciti.CicloSollecito.bpmn20.xml"})
public void simpleProcessTest() {
org.activiti.engine.ActivitiException: resource '/diagrams/ControlloCrediti.GestioneSolleciti.CicloSollecito.bpmn20.xml' not found
at org.activiti.engine.impl.repository.DeploymentBuilderImpl.addClasspathResource(DeploymentBuilderImpl.java:58)
getClass().getResource("/diagrams/ControlloCrediti.GestioneSolleciti.CicloSollecito.bpmn20.xml")Ii find the resource , successfully .06-10-2011 02:37 AM
06-10-2011 02:39 AM
Do you check the classpath in your test? Make sure the tests run with the diagrams folder on your classpath…
getClass().getResource("/diagrams/ControlloCrediti.GestioneSolleciti.CicloSollecito.bpmn20.xml")Do you run the tests in eclipse or maven?
06-10-2011 03:35 AM
@Before
public void init() throws IOException {
URL pDef = getClass()
.getResource(
"/diagrams/xx.xx.bpmn20.xml");
DeploymentBuilder db = repositoryService.createDeployment();
InputStream in = pDef.openStream();
try {
db.addInputStream("xx.xx.bpmn20.xml",in);
} finally {
IOUtils.closeQuietly(in);
}
deploymentId = db.deploy().getId();
}
Using the follow code in place do not work:@Before
public void init() throws IOException {
DeploymentBuilder db = repositoryService.createDeployment();
db.addClasspathResource("/diagrams/xx.xx.bpmn20.xml");
deploymentId = db.deploy().getId();
}Tags
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.