Camunda 7.17 possible bug: JUnit5 process tests require public @Test method

Probably a bug in Camunda 7.17.

When running Camunda 7.17 process test with JUnit 5 it is required to declare @Test method as public:

@SpringBootTest
@Deployment(resources = "test.bpmn")
class Test {
  @RegisterExtension ProcessEngineExtension processEngine;

  @Test
  public void test() {
    // size == 1
    this.processEngine.getRepositoryService().createProcessDefinitionQuery().list();
  }
}

declaring it as package scoped (default JUnit 5 recommendation) leads to @Deployment not to trigger properly:

@SpringBootTest
@Deployment(resources = "test.bpmn")
class Test {
  @RegisterExtension ProcessEngineExtension processEngine;

  @Test
  void test() {
    // size == 0
    this.processEngine.getRepositoryService().createProcessDefinitionQuery().list();
  }
}
2 Likes

Hi @mkadan,

That sounds like a bug. Can you create a bug report in Jira?
https://jira.camunda.com/secure/CreateIssue!default.jspa

We will qualify it and get back to you with our insights.

Best,
Tassilo

I run into the same problem and wondered if the bug is fixed. But I cannot find an approriate ticket for this in jira.camunda.org. @mkadan or anyone else, did you create a report? If not, I will do it.