%global namedreltag %{nil} %global namedversion %{version}%{?namedreltag} Name: jmock Version: 2.8.1 Release: 2%{?dist} Summary: Java library for testing code with mock objects License: BSD Url: http://www.jmock.org/ Source0: https://github.com/jmock-developers/jmock-library/archive/%{namedversion}.tar.gz BuildRequires: maven-local BuildRequires: mvn(cglib:cglib) BuildRequires: mvn(junit:junit) BuildRequires: mvn(org.apache.maven.plugins:maven-dependency-plugin) BuildRequires: mvn(org.beanshell:bsh) BuildRequires: mvn(org.codehaus.mojo:exec-maven-plugin) BuildRequires: mvn(org.hamcrest:hamcrest-library) BuildRequires: mvn(org.objenesis:objenesis) BuildRequires: mvn(org.ow2.asm:asm) BuildRequires: mvn(org.sonatype.oss:oss-parent:pom:) BuildArch: noarch %description Mock objects help you design and test the interactions between the objects in your programs. The jMock library: * makes it quick and easy to define mock objects, so you don't break the rhythm of programming. * lets you precisely specify the interactions between your objects, reducing the brittleness of your tests. * works well with the auto-completion and re-factoring features of your IDE * plugs into your favorite test framework * is easy to extend. %package javadoc Summary: Javadoc for %{name} %description javadoc This package contains javadoc for %{name}. %prep %setup -q -n %{name}-library-%{namedversion} %pom_remove_plugin :nexus-staging-maven-plugin %pom_remove_plugin :maven-javadoc-plugin %pom_remove_plugin :maven-source-plugin %pom_remove_plugin :maven-gpg-plugin testjar %pom_xpath_set "pom:dependency[pom:groupId = 'cglib' ]/pom:artifactId" cglib %pom_xpath_set "pom:dependency[pom:groupId = 'cglib' ]/pom:artifactId" cglib %{name} sed -i "s|%classpath|$(build-classpath objectweb-asm/asm)|" %{name}/pom.xml %pom_xpath_remove pom:build %{name}-example %pom_xpath_inject "pom:project" " src/main " %{name}-example # package org.jmock.integration.junit{3,4} do not exist %pom_add_dep org.%{name}:%{name}-junit3:'${project.version}' %{name}-example %pom_add_dep org.%{name}:%{name}-junit4:'${project.version}' %{name}-example %mvn_alias org.%{name}:%{name} :%{name}-script %mvn_package org.%{name}:%{name}::tests: %mvn_package org.%{name}:%{name}-junit3::tests: %build %mvn_build %install %mvn_install %files -f .mfiles %doc README* %license LICENSE.txt %files javadoc -f .mfiles-javadoc %license LICENSE.txt %changelog * Wed Jun 17 2015 Fedora Release Engineering - 2.8.1-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild * Wed Jun 03 2015 gil cattaneo 2.8.1-1 - updated to 2.8.1 * Fri Feb 06 2015 gil cattaneo 2.5.1-8 - introduce license macro * Sun Jun 08 2014 Fedora Release Engineering - 2.5.1-7 - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild * Thu May 22 2014 gil cattaneo 2.5.1-6 - Use .mfiles generated during build - Fix junit dep * Fri Mar 28 2014 Michael Simacek - 2.5.1-5 - Use Requires: java-headless rebuild (#1067528) * Fri Nov 15 2013 gil cattaneo 2.5.1-4 - use objectweb-asm3 * Sat Aug 03 2013 Fedora Release Engineering - 2.5.1-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild * Thu Feb 14 2013 Fedora Release Engineering - 2.5.1-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild * Thu Apr 19 2012 gil cattaneo 2.5.1-1 - initial rpm