Search code examples
javafitnesse

identify FitNesse test run with its Thread ID


I read that fitnesse is creating a new java process for each test run. I wrote the following code in Fixture class to print thread Id.

Thread.currentThread().getId()

When Run multiple tests in parallel I am getting the Thread ID as 1 for all the tests.

Does anyone have an idea, why I am getting the same ID?


Solution

  • The executor thread may get the same ID in different processes if each test runs as a separate process. You should get and display the process ID with the thread ID to prove this.