Update to upstream version 2.1
This commit is contained in:
parent
21d87b440a
commit
f6468e545d
1
.gitignore
vendored
1
.gitignore
vendored
@ -12,3 +12,4 @@
|
|||||||
/noarch
|
/noarch
|
||||||
/.build-*.log
|
/.build-*.log
|
||||||
/hamcrest-java-1.3.tar.gz
|
/hamcrest-java-1.3.tar.gz
|
||||||
|
/hamcrest-2.1.tar.gz
|
||||||
|
137
hamcrest.spec
137
hamcrest.spec
@ -29,135 +29,86 @@
|
|||||||
#
|
#
|
||||||
|
|
||||||
Name: hamcrest
|
Name: hamcrest
|
||||||
Version: 1.3
|
Version: 2.1
|
||||||
Release: 24%{?dist}
|
Release: 1%{?dist}
|
||||||
Summary: Library of matchers for building test expressions
|
Summary: Library of matchers for building test expressions
|
||||||
License: BSD
|
License: BSD
|
||||||
URL: https://github.com/hamcrest/JavaHamcrest
|
URL: https://github.com/hamcrest/JavaHamcrest
|
||||||
Source0: https://github.com/hamcrest/JavaHamcrest/archive/hamcrest-java-%{version}.tar.gz
|
Source0: https://github.com/hamcrest/JavaHamcrest/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz
|
||||||
|
Source1: https://repo1.maven.org/maven2/org/hamcrest/hamcrest/%{version}/hamcrest-%{version}.pom
|
||||||
|
|
||||||
Source8: hamcrest-core-MANIFEST.MF
|
BuildRequires: maven-local
|
||||||
Source9: hamcrest-library-MANIFEST.MF
|
BuildRequires: mvn(junit:junit)
|
||||||
Source11: hamcrest-integration-MANIFEST.MF
|
|
||||||
Source12: hamcrest-generator-MANIFEST.MF
|
|
||||||
|
|
||||||
Patch0: %{name}-%{version}-build.patch
|
|
||||||
Patch1: %{name}-%{version}-no-jarjar.patch
|
|
||||||
Patch3: %{name}-%{version}-javadoc.patch
|
|
||||||
Patch4: %{name}-%{version}-qdox-2.0.patch
|
|
||||||
Patch5: %{name}-%{version}-fork-javac.patch
|
|
||||||
|
|
||||||
Requires: qdox
|
|
||||||
Requires: easymock >= 3.0
|
|
||||||
Requires: %{name}-core = %{version}-%{release}
|
|
||||||
|
|
||||||
BuildRequires: javapackages-local
|
|
||||||
BuildRequires: ant
|
|
||||||
BuildRequires: ant-junit
|
|
||||||
BuildRequires: easymock
|
|
||||||
BuildRequires: junit
|
|
||||||
BuildRequires: qdox
|
|
||||||
BuildRequires: testng
|
|
||||||
|
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
|
|
||||||
|
Obsoletes: hamcrest-demo < 2.1
|
||||||
|
|
||||||
%description
|
%description
|
||||||
Provides a library of matcher objects (also known as constraints or predicates)
|
Provides a library of matcher objects (also known as constraints or predicates)
|
||||||
allowing 'match' rules to be defined declaratively, to be used in other
|
allowing 'match' rules to be defined declaratively, to be used in other
|
||||||
frameworks. Typical scenarios include testing frameworks, mocking libraries and
|
frameworks. Typical scenarios include testing frameworks, mocking libraries and
|
||||||
UI validation rules.
|
UI validation rules.
|
||||||
|
|
||||||
%package core
|
|
||||||
Summary: Core API of hamcrest matcher framework.
|
|
||||||
|
|
||||||
%description core
|
|
||||||
The core API of hamcrest matcher framework to be used by third-party framework providers.
|
|
||||||
This includes the a foundation set of matcher implementations for common operations.
|
|
||||||
|
|
||||||
%package javadoc
|
%package javadoc
|
||||||
Summary: Javadoc for %{name}
|
Summary: Javadoc for %{name}
|
||||||
|
|
||||||
%description javadoc
|
%description javadoc
|
||||||
Javadoc for %{name}.
|
Javadoc for %{name}.
|
||||||
|
|
||||||
%package demo
|
|
||||||
Summary: Demos for %{name}
|
|
||||||
Requires: %{name} = %{version}-%{release}
|
|
||||||
Requires: junit
|
|
||||||
Requires: testng
|
|
||||||
|
|
||||||
%description demo
|
|
||||||
Demonstrations and samples for %{name}.
|
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n JavaHamcrest-%{name}-java-%{version}
|
%setup -q -n JavaHamcrest-%{version}
|
||||||
|
|
||||||
find . -type f -name "*.jar" | xargs -t rm
|
rm -rf docs
|
||||||
rm -fr hamcrest-integration/src/main/java/org/hamcrest/integration/JMock1Adapter.java
|
rm -rf *gradle*
|
||||||
rm -fr hamcrest-integration/src/main/java/org/hamcrest/JMock1Matchers.java
|
rm -rf */*.gradle
|
||||||
rm -fr hamcrest-unit-test/src/main/java/org/hamcrest/integration/JMock1AdapterTest.java
|
|
||||||
# BUILD/hamcrest-1.1/lib/generator/qdox-1.6.1.jar.no
|
|
||||||
ln -sf $(build-classpath qdox) lib/generator/
|
|
||||||
# BUILD/hamcrest-1.1/lib/integration/easymock-2.2.jar.no
|
|
||||||
ln -sf $(build-classpath easymock3) lib/integration/
|
|
||||||
# BUILD/hamcrest-1.1/lib/integration/jmock-1.10RC1.jar.no
|
|
||||||
ln -sf $(build-classpath jmock) lib/integration/
|
|
||||||
# BUILD/hamcrest-1.1/lib/integration/testng-4.6-jdk15.jar.no
|
|
||||||
ln -sf $(build-classpath testng-jdk15) lib/integration/
|
|
||||||
|
|
||||||
%patch0 -p1
|
mv hamcrest/src .
|
||||||
%patch1 -p1
|
rm -rf hamcrest
|
||||||
%patch3 -p1
|
rm -rf hamcrest-core
|
||||||
%patch4 -p1
|
rm -rf hamcrest-integration
|
||||||
%patch5 -p1
|
rm -rf hamcrest-library
|
||||||
|
|
||||||
|
cp -p %{SOURCE1} pom.xml
|
||||||
|
%pom_add_dep junit:junit
|
||||||
|
%pom_xpath_inject pom:project '
|
||||||
|
<build>
|
||||||
|
<plugins>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-compiler-plugin</artifactId>
|
||||||
|
<version>3.8.1</version>
|
||||||
|
<configuration>
|
||||||
|
<source>1.8</source>
|
||||||
|
<target>1.8</target>
|
||||||
|
</configuration>
|
||||||
|
</plugin>
|
||||||
|
</plugins>
|
||||||
|
</build>'
|
||||||
|
|
||||||
|
%mvn_alias org.hamcrest:hamcrest org.hamcrest:hamcrest-all
|
||||||
|
%mvn_alias org.hamcrest:hamcrest org.hamcrest:hamcrest-core
|
||||||
|
%mvn_alias org.hamcrest:hamcrest org.hamcrest:hamcrest-library
|
||||||
|
|
||||||
sed -i 's/\r//' LICENSE.txt
|
sed -i 's/\r//' LICENSE.txt
|
||||||
|
|
||||||
%build
|
%build
|
||||||
export CLASSPATH=$(build-classpath qdox)
|
%mvn_build
|
||||||
export OPT_JAR_LIST="junit ant/ant-junit"
|
|
||||||
# The unit-test goal is switched off as some tests fail with JDK 7
|
|
||||||
# see https://github.com/hamcrest/JavaHamcrest/issues/30
|
|
||||||
ant -Dant.build.javac.source=1.5 -Dversion=%{version} -Dbuild.sysclasspath=last clean core generator library bigjar javadoc
|
|
||||||
|
|
||||||
# inject OSGi manifests
|
|
||||||
jar ufm build/%{name}-core-%{version}.jar %{SOURCE8}
|
|
||||||
jar ufm build/%{name}-library-%{version}.jar %{SOURCE9}
|
|
||||||
jar ufm build/%{name}-integration-%{version}.jar %{SOURCE11}
|
|
||||||
jar ufm build/%{name}-generator-%{version}.jar %{SOURCE12}
|
|
||||||
|
|
||||||
%install
|
%install
|
||||||
sed -i 's/@VERSION@/%{version}/g' pom/*.pom
|
%mvn_install
|
||||||
|
|
||||||
%mvn_artifact pom/hamcrest-parent.pom
|
|
||||||
|
|
||||||
for mod in all core generator library integration; do
|
|
||||||
%mvn_artifact pom/hamcrest-$mod.pom build/%{name}-$mod-%{version}.jar
|
|
||||||
done
|
|
||||||
|
|
||||||
%mvn_package :hamcrest-parent core
|
|
||||||
%mvn_package :hamcrest-core core
|
|
||||||
|
|
||||||
%mvn_file ':hamcrest-{*}' %{name}/@1
|
|
||||||
|
|
||||||
# demo
|
|
||||||
install -d -m 755 $RPM_BUILD_ROOT%{_datadir}/%{name}
|
|
||||||
cp -pr %{name}-examples $RPM_BUILD_ROOT%{_datadir}/%{name}/
|
|
||||||
|
|
||||||
%mvn_install -J build/temp/hamcrest-all-1.3-javadoc.jar.contents/
|
|
||||||
|
|
||||||
%files -f .mfiles
|
%files -f .mfiles
|
||||||
|
%doc README.md
|
||||||
%files core -f .mfiles-core
|
|
||||||
%license LICENSE.txt
|
%license LICENSE.txt
|
||||||
|
|
||||||
%files javadoc -f .mfiles-javadoc
|
%files javadoc -f .mfiles-javadoc
|
||||||
%license LICENSE.txt
|
%license LICENSE.txt
|
||||||
|
|
||||||
%files demo
|
|
||||||
%{_datadir}/%{name}
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon Aug 19 2019 Marian Koncek <mkoncek@redhat.com> - 2.1-1
|
||||||
|
- Update to upstream version 2.1
|
||||||
|
|
||||||
* Fri May 24 2019 Mikolaj Izdebski <mizdebsk@redhat.com> - 1.3-24
|
* Fri May 24 2019 Mikolaj Izdebski <mizdebsk@redhat.com> - 1.3-24
|
||||||
- Mass rebuild for javapackages-tools 201901
|
- Mass rebuild for javapackages-tools 201901
|
||||||
|
|
||||||
|
2
sources
2
sources
@ -1 +1 @@
|
|||||||
SHA512 (hamcrest-java-1.3.tar.gz) = 4356df7b5b78f821847fde027b416b49b8456e84ab2ec98c2982adf54e2bdc01a5ca2c2b5425620c5ee34bfe3f95ea43c77190504f76ddc9f8b93b137a4ca54b
|
SHA512 (hamcrest-2.1.tar.gz) = 15a67b040cf95141b241e201bd5ff14b913dea53fd2dc8305e8d2768e5e214457efa1eed75e66d95a0be575b6c5b611e281886c7661d75e186165c3861698abc
|
||||||
|
Loading…
Reference in New Issue
Block a user