[htmlunit] Initial package
Andy Grimm
arg at fedoraproject.org
Mon Dec 19 14:01:53 UTC 2011
commit e9de2d30cb6746c9397bb43a16d6b2965c68d94e
Author: Andy Grimm <agrimm at gmail.com>
Date: Mon Dec 19 09:00:48 2011 -0500
Initial package
.gitignore | 1 +
htmlunit-2.9-dep-fixes.patch | 68 ++++++++++++++++++++++++
htmlunit-2.9-no-jfreechart.patch | 15 +++++
htmlunit-2.9-old-nekohtml.patch | 11 ++++
htmlunit.spec | 108 ++++++++++++++++++++++++++++++++++++++
sources | 1 +
6 files changed, 204 insertions(+), 0 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index e69de29..ce18376 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/htmlunit-2.9-src.zip
diff --git a/htmlunit-2.9-dep-fixes.patch b/htmlunit-2.9-dep-fixes.patch
new file mode 100644
index 0000000..10b7023
--- /dev/null
+++ b/htmlunit-2.9-dep-fixes.patch
@@ -0,0 +1,68 @@
+--- pom.xml.orig 2011-09-08 11:32:01.931000596 -0400
++++ pom.xml 2011-09-08 13:29:26.319001237 -0400
+@@ -678,6 +678,11 @@
+ </exclusions>
+ </dependency>
+ <dependency>
++ <groupId>xalan</groupId>
++ <artifactId>xsltc</artifactId>
++ <version>2.7.1</version>
++ </dependency>
++ <dependency>
+ <groupId>commons-collections</groupId>
+ <artifactId>commons-collections</artifactId>
+ <version>3.2.1</version>
+@@ -723,7 +728,7 @@
+ <dependency>
+ <groupId>net.sourceforge.nekohtml</groupId>
+ <artifactId>nekohtml</artifactId>
+- <version>1.9.15</version>
++ <version>1.9.14</version>
+ <exclusions>
+ <exclusion>
+ <groupId>xerces</groupId>
+@@ -754,12 +759,6 @@
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+- <groupId>gsbase</groupId>
+- <artifactId>gsbase</artifactId>
+- <version>2.0.1</version>
+- <scope>test</scope>
+- </dependency>
+- <dependency>
+ <groupId>org.easymock</groupId>
+ <artifactId>easymock</artifactId>
+ <version>3.0</version>
+@@ -802,31 +801,6 @@
+ <version>1.0.12</version>
+ <scope>test</scope>
+ </dependency>
+- <!-- WebDriver -->
+- <dependency>
+- <groupId>org.seleniumhq.selenium</groupId>
+- <artifactId>selenium-htmlunit-driver</artifactId>
+- <version>2.1.0</version>
+- <scope>test</scope>
+- <exclusions>
+- <exclusion>
+- <groupId>net.sourceforge.htmlunit</groupId>
+- <artifactId>htmlunit</artifactId>
+- </exclusion>
+- </exclusions>
+- </dependency>
+- <dependency>
+- <groupId>org.seleniumhq.selenium</groupId>
+- <artifactId>selenium-ie-driver</artifactId>
+- <version>2.1.0</version>
+- <scope>test</scope>
+- </dependency>
+- <dependency>
+- <groupId>org.seleniumhq.selenium</groupId>
+- <artifactId>selenium-firefox-driver</artifactId>
+- <version>2.1.0</version>
+- <scope>test</scope>
+- </dependency>
+ </dependencies>
+ <distributionManagement>
+ <site>
diff --git a/htmlunit-2.9-no-jfreechart.patch b/htmlunit-2.9-no-jfreechart.patch
new file mode 100644
index 0000000..642fc2e
--- /dev/null
+++ b/htmlunit-2.9-no-jfreechart.patch
@@ -0,0 +1,15 @@
+--- pom.xml 2011-09-08 13:37:11.100001311 -0400
++++ pom.xml.new 2011-09-08 13:38:46.047001426 -0400
+@@ -795,12 +795,6 @@
+ <version>1.6.1</version>
+ <scope>test</scope>
+ </dependency>
+- <dependency>
+- <groupId>jfree</groupId>
+- <artifactId>jfreechart</artifactId>
+- <version>1.0.12</version>
+- <scope>test</scope>
+- </dependency>
+ </dependencies>
+ <distributionManagement>
+ <site>
diff --git a/htmlunit-2.9-old-nekohtml.patch b/htmlunit-2.9-old-nekohtml.patch
new file mode 100644
index 0000000..5451fa4
--- /dev/null
+++ b/htmlunit-2.9-old-nekohtml.patch
@@ -0,0 +1,11 @@
+--- src/main/java/com/gargoylesoftware/htmlunit/html/HTMLParser.java.orig 2011-08-09 08:23:08.000000000 -0400
++++ src/main/java/com/gargoylesoftware/htmlunit/html/HTMLParser.java 2011-09-08 13:57:00.631001358 -0400
+@@ -408,8 +408,6 @@
+ setProperty("http://cyberneko.org/html/properties/names/elems", "default");
+ setFeature("http://cyberneko.org/html/features/report-errors", reportErrors);
+ setFeature(FEATURE_PARSE_NOSCRIPT, !webClient.isJavaScriptEnabled());
+- setFeature(HTMLScanner.ALLOW_SELFCLOSING_IFRAME,
+- !webClient.getBrowserVersion().hasFeature(BrowserVersionFeatures.HTMLIFRAME_IGNORE_SELFCLOSING));
+
+ setContentHandler(this);
+ setLexicalHandler(this); //comments and CDATA
diff --git a/htmlunit.spec b/htmlunit.spec
new file mode 100644
index 0000000..a0a555e
--- /dev/null
+++ b/htmlunit.spec
@@ -0,0 +1,108 @@
+Name: htmlunit
+Version: 2.9
+Release: 1%{?dist}
+Summary: A headless web browser for automated testing
+
+Group: Development/Libraries
+License: ASL 2.0
+URL: http://htmlunit.sourceforge.net/
+Source0: http://downloads.sourceforge.net/%{name}/%{name}-2.9-src.zip
+Patch0: %{name}-%{version}-dep-fixes.patch
+Patch1: %{name}-%{version}-no-jfreechart.patch
+Patch2: %{name}-%{version}-old-nekohtml.patch
+
+BuildArch: noarch
+
+BuildRequires: jpackage-utils
+BuildRequires: apache-commons-codec
+BuildRequires: apache-commons-collections
+BuildRequires: apache-commons-io
+BuildRequires: apache-commons-lang
+BuildRequires: apache-commons-logging
+BuildRequires: apache-commons-io
+BuildRequires: apache-commons-fileupload
+BuildRequires: cssparser
+BuildRequires: nekohtml
+BuildRequires: jakarta-commons-httpclient
+BuildRequires: htmlunit-core-js
+BuildRequires: java-devel
+BuildRequires: maven
+BuildRequires: maven-compiler-plugin
+BuildRequires: maven-enforcer-plugin
+BuildRequires: maven-install-plugin
+BuildRequires: maven-jar-plugin
+BuildRequires: maven-javadoc-plugin
+BuildRequires: maven-release-plugin
+BuildRequires: maven-resources-plugin
+BuildRequires: maven-surefire-plugin
+BuildRequires: xalan-j2
+BuildRequires: xalan-j2-xsltc
+
+Requires: jpackage-utils
+Requires: java
+Requires: xalan-j2
+Requires: xalan-j2-xsltc
+Requires: apache-commons-codec
+Requires: apache-commons-collections
+Requires: apache-commons-io
+Requires: apache-commons-lang
+Requires: apache-commons-logging
+Requires: apache-commons-io
+Requires: apache-commons-fileupload
+Requires: cssparser
+Requires: nekohtml
+Requires: jakarta-commons-httpclient
+Requires: htmlunit-core-js
+
+%description
+HtmlUnit is a "GUI-Less browser for Java programs". It models HTML
+documents and provides an API for automated testing of
+web applications.
+
+%package javadoc
+Summary: API documentation for %{name}
+Group: Documentation
+Requires: jpackage-utils
+
+%description javadoc
+This package contains the API documentation for %{name}.
+
+%prep
+%setup -q
+%patch0 -p 0
+%patch1 -p 0
+%patch2 -p 0
+
+%build
+# enabling tests would require packaging some selenium plugins
+mvn-rpmbuild -Dmaven.test.skip=true package javadoc:aggregate
+
+%install
+
+install -d -m 755 $RPM_BUILD_ROOT%{_javadir}
+cp -p target/%{name}-%{version}.jar $RPM_BUILD_ROOT%{_javadir}/%{name}.jar
+
+install -d -m 755 $RPM_BUILD_ROOT%{_javadocdir}/%{name}
+cp -rp target/site/apidocs/* $RPM_BUILD_ROOT%{_javadocdir}/%{name}
+
+install -d -m 755 $RPM_BUILD_ROOT%{_mavenpomdir}
+install -pm 644 pom.xml \
+ $RPM_BUILD_ROOT%{_mavenpomdir}/JPP-%{name}.pom
+
+%add_maven_depmap JPP-%{name}.pom %{name}.jar
+
+
+%files
+%doc LICENSE.txt
+%{_mavenpomdir}/JPP-%{name}.pom
+%{_mavendepmapfragdir}/%{name}
+%{_javadir}/%{name}.jar
+%doc
+
+%files javadoc
+%doc LICENSE.txt
+%{_javadocdir}/%{name}
+
+%changelog
+* Fri Sep 02 2011 Andy Grimm <agrimm at gmail.com> - 2.9-1
+- Initial package
diff --git a/sources b/sources
index e69de29..335164f 100644
--- a/sources
+++ b/sources
@@ -0,0 +1 @@
+52604527e9aaab2183dfd0be43400faa htmlunit-2.9-src.zip
More information about the scm-commits
mailing list