class Saxon < Formula desc "XSLT and XQuery processor" homepage "https://saxon.sourceforge.io" url "https://downloads.sourceforge.net/project/saxon/Saxon-HE/9.7/SaxonHE9-7-0-4J.zip" version "9.7.0.4" sha256 "b83d9abb4ed2b333a965c7c41787f7073d5af4d5a72e26ad6a551d1bbf9633de" bottle :unneeded def install libexec.install Dir["*.jar", "doc", "notices"] bin.write_jar_script libexec/"saxon9he.jar", "saxon" end test do (testpath/"test.xml").write <<-XML.undent It works! XML (testpath/"test.xsl").write <<-XSL.undent

XSL assert_equal <<-HTML.undent.chop, shell_output("#{bin}/saxon test.xml test.xsl")

It works!

HTML end end