public void testReran(String testId, String className, String testName, int statusCode, String trace, String expectedResult, String actualResult) { TestElement testElement= getTestElement(testId); if (! (testElement instanceof TestCaseElement)) { logUnexpectedTest(testId, testElement); return; } TestCaseElement testCaseElement= (TestCaseElement) testElement;   int oldStatus= testCaseElement.getStatus().getOldCode(); if (statusCode == oldStatus) return; if (oldStatus == ITestRunListener.STATUS_OK) { if (statusCode == ITestRunListener.STATUS_FAILURE) fFailureCount++; else if (statusCode == ITestRunListener.STATUS_ERROR) fErrorCount++; } else if (oldStatus == ITestRunListener.STATUS_ERROR) { if (statusCode == ITestRunListener.STATUS_OK) fErrorCount--; else if (statusCode == ITestRunListener.STATUS_FAILURE) { fErrorCount--; fFailureCount++; } } else if (oldStatus == ITestRunListener.STATUS_FAILURE) { if (statusCode == ITestRunListener.STATUS_OK) fFailureCount--; else if (statusCode == ITestRunListener.STATUS_ERROR) { fFailureCount--; fErrorCount++; } } Status status= Status.convert(statusCode); testCaseElement.setStatus(status, trace, expectedResult, actualResult);  Object[] listeners= fSessionListeners.getListeners(); for (int i= 0; i < listeners.length; ++i) {  ((ITestSessionListener) listeners[i]).testReran(testCaseElement, status, trace, expectedResult, actualResult); }
public void testReran(String testId, String testClass, String testName, int status, String trace) { testReran(testId, testClass, testName, status, trace, "", "");
		public void testReran(String testId, String className, String testName, int statusCode, String trace, String expectedResult, String actualResult) {			TestElement testElement= getTestElement(testId);			if (! (testElement instanceof TestCaseElement)) {				logUnexpectedTest(testId, testElement); //TODO: rerun suites?				return;			}			TestCaseElement testCaseElement= (TestCaseElement) testElement;						//TODO: convert			int oldStatus= testCaseElement.getStatus().getOldCode();			if (statusCode == oldStatus)				return;			if (oldStatus == ITestRunListener.STATUS_OK) {				if (statusCode == ITestRunListener.STATUS_FAILURE) 					fFailureCount++;				else if (statusCode == ITestRunListener.STATUS_ERROR)					fErrorCount++;			} else if (oldStatus == ITestRunListener.STATUS_ERROR) {				if (statusCode == ITestRunListener.STATUS_OK) 					fErrorCount--;				else if (statusCode == ITestRunListener.STATUS_FAILURE) {					fErrorCount--;					fFailureCount++;				}			} else if (oldStatus == ITestRunListener.STATUS_FAILURE) {				if (statusCode == ITestRunListener.STATUS_OK) 					fFailureCount--;				else if (statusCode == ITestRunListener.STATUS_ERROR) {					fFailureCount--;					fErrorCount++;				}			}						Status status= Status.convert(statusCode);			testCaseElement.setStatus(status, trace, expectedResult, actualResult);						Object[] listeners= fSessionListeners.getListeners();			for (int i= 0; i < listeners.length; ++i) {				//TODO: post old & new status?				((ITestSessionListener) listeners[i]).testReran(testCaseElement, status, trace, expectedResult, actualResult);			}		}