
package org.eclipse.birt.report.tests.engine.regression;

import java.util.ArrayList;

import org.eclipse.birt.report.tests.engine.EngineCase;

/**
 * <b>Bug description</b>
 * <p>
 * Bad Data Source and Data Set Javascript event handlers are ignored
 * 
 * <p>
 * <b>Test description</b>
 * <p>
 * This test make sure that the bag data source and data set Javascript will
 * throw the exception.
 * 
 */

public class Regression_121109 extends EngineCase
{

	private final String testDatasource = "regression_121109_Datasource";
	private final String testDataset = "regression_121109_Dataset";

	private String inputFile = null;
	private String outputFile = null;

	public void test_Regression_121109_Datasource( ) throws Exception
	{
		inputFile = testDatasource + ".rptdesign";
		outputFile = testDatasource + ".html";

		ArrayList errors = this.runAndThenRender( inputFile, outputFile, "all",
				"html" );

		assertTrue( errors.size( ) > 0 );

	}

	public void test_Regression_121109_Dataset( ) throws Exception
	{
		inputFile = testDataset + ".rptdesign";
		outputFile = testDataset + ".html";

		ArrayList errors = this.runAndThenRender( inputFile, outputFile, "all",
				"html" );

		assertTrue( errors.size( ) > 0 );
	}

}
