⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 abstractconfigurablejasperreportsviewtests.java

📁 struts+spring 源码 希望能给大家带来帮助
💻 JAVA
字号:
package org.springframework.web.servlet.view.jasperreports;

import org.springframework.context.support.StaticApplicationContext;

/**
 * @author robh
 */
public abstract class AbstractConfigurableJasperReportsViewTests extends AbstractJasperReportsViewTests {

	public void testSetInvalidExporterClass() throws Exception {
		try {
			new ConfigurableJasperReportsView().setExporterClass(String.class);
			fail("Should not be able to set invalid view class.");
		}
		catch (IllegalArgumentException ex) {
			// success
		}
	}

	public void testNoConfiguredExporter() throws Exception {
		ConfigurableJasperReportsView view = new ConfigurableJasperReportsView();
		view.setUrl(COMPILED_REPORT);
		try {
			view.setApplicationContext(new StaticApplicationContext());
			fail("Should not be able to setup view class without an exporter class.");
		}
		catch (IllegalArgumentException e) {
			// success
		}
	}
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -