1 package org.apache.tools.ant.taskdefs.optional; 2 3 19 20 import org.apache.tools.ant.taskdefs.XSLTLiaison; 21 22 import java.io.File ; 23 24 27 public class XalanLiaisonTest extends AbstractXSLTLiaisonTest { 28 public XalanLiaisonTest(String name){ 29 super(name); 30 } 31 32 public void tearDown() { 33 File f = new File ("xalan1-redirect-out.tmp"); 34 if (f.exists()) { 35 f.delete(); 36 } 37 } 38 39 protected XSLTLiaison createLiaison() throws Exception { 40 return new XalanLiaison(); 41 } 42 43 public void testXalan1Redirect() throws Exception { 44 File xsl = getFile("/taskdefs/optional/xalan-redirect-in.xsl"); 45 liaison.setStylesheet(xsl); 46 File out = new File ("xalan1-redirect-out-dummy.tmp"); 47 File in = getFile("/taskdefs/optional/xsltliaison-in.xsl"); 48 try { 49 liaison.addParam("xalan-version", "1"); 50 liaison.transform(in, out); 51 } finally { 52 out.delete(); 53 } 54 } 55 } 56 57 | Popular Tags |