package org.seasar.dao.unit;

import java.util.List;

import junit.framework.Assert;

import org.seasar.extension.dataset.DataSet;
import org.seasar.extension.unit.S2TestCase;

/**
 * @author higa
 *  
 */
public class S2DaoTestCase extends S2TestCase {

	/**
	 * @param name
	 */
	public S2DaoTestCase(String name) {
		super(name);
	}

	protected void assertBeanEquals(String message, DataSet expected,
			Object bean) {

		S2DaoBeanReader reader = new S2DaoBeanReader(bean,
				getDatabaseMetaData());
		Assert.assertEquals(message, expected, reader.read());
	}

	protected void assertBeanListEquals(String message, DataSet expected,
			List list) {

		S2DaoBeanListReader reader = new S2DaoBeanListReader(list,
				getDatabaseMetaData());
		Assert.assertEquals(message, expected, reader.read());
	}

}