Newer
Older
CollabUnit / src / main / uk / org / floop / collabunit / CollabRunner.java
/*
 * Created on Sep 7, 2004
 *
 * TODO To change the template for this generated file go to
 * Window - Preferences - Java - Code Style - Code Templates
 */
package uk.org.floop.collabunit;

import junit.framework.Test;
import junit.framework.TestResult;
import junit.runner.BaseTestRunner;

/**
 * @author alex
 *
 * TODO To change the template for this generated type comment go to
 * Window - Preferences - Java - Code Style - Code Templates
 */
public class CollabRunner extends BaseTestRunner {

	private TestResult results;

	/* (non-Javadoc)
	 * @see junit.runner.BaseTestRunner#testStarted(java.lang.String)
	 */
	public void testStarted(String testName) {
		// TODO Auto-generated method stub

	}

	/* (non-Javadoc)
	 * @see junit.runner.BaseTestRunner#testEnded(java.lang.String)
	 */
	public void testEnded(String testName) {
		// TODO Auto-generated method stub

	}

	/**
	 * 
	 */
	public CollabRunner() {
	    results = new TestResult();
	    results.addListener(this);
	}
	/* (non-Javadoc)
	 * @see junit.runner.BaseTestRunner#testFailed(int, junit.framework.Test, java.lang.Throwable)
	 */
	public void testFailed(int status, Test test, Throwable t) {
		// TODO Auto-generated method stub

	}

	/* (non-Javadoc)
	 * @see junit.runner.BaseTestRunner#runFailed(java.lang.String)
	 */
	protected void runFailed(String message) {
		// TODO Auto-generated method stub

	}

	/**
	 * @param test
	 * @return
	 */
	public boolean runTest(Test test)
	{
		test.run(results);
		return results.wasSuccessful();
	}
}