Project: JDT
Bug 283304 [JUnit] ITestRunSession should return launched project
Reported: 2009-07-13 07:55:31 | Status: resolved fixed

Please add access for getLaunchedProject() of org.eclipse.jdt.internal.junit.model.TestRunSession in org.eclipse.jdt.junit.model.ITestRunSession. My problem is that i need the launched project to reproduce and analyse the testCases (ITestCaseElement). The only "data" i get is the testClassName and testMethodName but that is not unique in the workspace. If you make getLaunchedProject() public over ITestRunSession, i will find the correct testCase everytime correct. Workaround is so cast the org.eclipse.jdt.junit.model.ITestRunSession object into org.eclipse.jdt.internal.junit.model.TestRunSession and invoke getLaunchedProject(). But this is the bad way cause TestRunSession is internal.

Files changed in fix:
org.eclipse.jdt.junit.core/src/org/eclipse/jdt/internal/junit/model/TestRunSession.java org.eclipse.jdt.junit.core/src/org/eclipse/jdt/junit/model/ITestRunSession.java org.eclipse.jdt.junit/src/org/eclipse/jdt/internal/junit/model/TestRunSession.java org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/model/ITestRunSession.java