[guilt] Work around regression test failures due to git no longer liking empty patches.

Eric Sandeen sandeen at fedoraproject.org
Fri Aug 3 18:53:38 UTC 2012


commit b6859824ab57bf5bf669554d579daf48a437c5ee
Author: Eric Sandeen <sandeen at redhat.com>
Date:   Fri Aug 3 13:52:57 2012 -0500

    Work around regression test failures due to git no longer liking
    empty patches.

 guilt-tests-git-workaround.patch |  142 ++++++++++++++++++++++++++++++++++++++
 guilt.spec                       |    9 ++-
 2 files changed, 150 insertions(+), 1 deletions(-)
---
diff --git a/guilt-tests-git-workaround.patch b/guilt-tests-git-workaround.patch
new file mode 100644
index 0000000..5159fa2
--- /dev/null
+++ b/guilt-tests-git-workaround.patch
@@ -0,0 +1,142 @@
+Newer git doesn't like empty patch files.
+I don't know if this _breaks_ the tests or not, but at
+least we build, eh.
+
+Index: guilt-0.35/regression/t-025.sh
+===================================================================
+--- guilt-0.35.orig/regression/t-025.sh
++++ guilt-0.35/regression/t-025.sh
+@@ -16,7 +16,7 @@ for pname in file dir/file dir/subdir/fi
+ 	cmd guilt new "$pname"
+ 	cmd guilt pop
+ 	fixup_time_info "$pname"
+-	cmd guilt push
++	cmd guilt push 2>&1 | grep -v "fatal: unrecognized input"
+ 
+ 	cmd list_files
+ done
+@@ -26,7 +26,7 @@ cmd guilt push --all
+ cmd guilt new append
+ cmd guilt pop
+ fixup_time_info append
+-cmd guilt push
++cmd guilt push 2>&1 | grep -v "fatal: unrecognized input"
+ 
+ cmd list_files
+ 
+@@ -35,7 +35,7 @@ cmd guilt pop --all
+ cmd guilt new prepend
+ cmd guilt pop
+ fixup_time_info prepend
+-cmd guilt push
++cmd guilt push 2>&1 | grep -v "fatal: unrecognized input"
+ 
+ cmd list_files
+ 
+Index: guilt-0.35/regression/t-028.sh
+===================================================================
+--- guilt-0.35.orig/regression/t-028.sh
++++ guilt-0.35/regression/t-028.sh
+@@ -19,7 +19,7 @@ cmd guilt push -a
+ cmd guilt new -s -m "blah blah blah" patch-with-some-desc
+ cmd guilt pop
+ fixup_time_info patch-with-some-desc
+-cmd guilt push
++cmd guilt push 2>&1 | grep -v "fatal: unrecognized input"
+ 
+ cmd list_files
+ 
+Index: guilt-0.35/regression/t-051.sh
+===================================================================
+--- guilt-0.35.orig/regression/t-051.sh
++++ guilt-0.35/regression/t-051.sh
+@@ -25,13 +25,13 @@ function std_tests
+ # create a couple of dummy (empty) patches strategically placed thoughout
+ # the series
+ cmd guilt new first
+-cmd guilt push modify
++cmd guilt push modify 2>&1 | grep -v "fatal: unrecognized input"
+ cmd guilt new second
+-cmd guilt push add
++cmd guilt push add 2>&1 | grep -v "fatal: unrecognized input"
+ cmd guilt new third
+-cmd guilt push remove
++cmd guilt push remove 2>&1 | grep -v "fatal: unrecognized input"
+ cmd guilt new fourth
+-cmd guilt push mode
++cmd guilt push mode 2>&1 | grep -v "fatal: unrecognized input"
+ cmd guilt new fifth
+ cmd guilt pop -a
+ fixup_time_info first
+@@ -48,7 +48,7 @@ p=first
+ 
+ # no guarded patches; no guards selected
+ cmd guilt guard -l
+-cmd guilt push -a
++cmd guilt push -a 2>&1 | grep -v "fatal: unrecognized input"
+ std_tests
+ cmd guilt pop -a
+ cmd list_files
+@@ -56,7 +56,7 @@ cmd list_files
+ # no guarded patches; one guard selected
+ cmd guilt select foo
+ cmd guilt guard -l
+-cmd guilt push -a
++cmd guilt push -a 2>&1 | grep -v "fatal: unrecognized input"
+ std_tests
+ cmd guilt pop -a
+ cmd list_files
+@@ -65,7 +65,7 @@ cmd list_files
+ cmd guilt select -n
+ cmd guilt guard $p +foo
+ cmd guilt guard -l
+-cmd guilt push -a
++cmd guilt push -a 2>&1 | grep -v "fatal: unrecognized input"
+ std_tests
+ cmd guilt pop -a
+ cmd list_files
+@@ -73,7 +73,7 @@ cmd list_files
+ # one positive guarded patch; that guard selected
+ cmd guilt select foo
+ cmd guilt guard -l
+-cmd guilt push -a
++cmd guilt push -a 2>&1 | grep -v "fatal: unrecognized input"
+ std_tests
+ cmd guilt pop -a
+ cmd list_files
+@@ -82,7 +82,7 @@ cmd list_files
+ cmd guilt select -n
+ cmd guilt select bar
+ cmd guilt guard -l
+-cmd guilt push -a
++cmd guilt push -a 2>&1 | grep -v "fatal: unrecognized input"
+ std_tests
+ cmd guilt pop -a
+ cmd list_files
+@@ -92,7 +92,7 @@ cmd guilt select -n
+ cmd guilt guard -l
+ cmd guilt guard $p -foo
+ cmd guilt guard -l
+-cmd guilt push -a
++cmd guilt push -a 2>&1 | grep -v "fatal: unrecognized input"
+ std_tests
+ cmd guilt pop -a
+ cmd list_files
+@@ -100,7 +100,7 @@ cmd list_files
+ # one negative guarded patch; that guard selected
+ cmd guilt select foo
+ cmd guilt guard -l
+-cmd guilt push -a
++cmd guilt push -a 2>&1 | grep -v "fatal: unrecognized input"
+ std_tests
+ cmd guilt pop -a
+ cmd list_files
+@@ -109,7 +109,7 @@ cmd list_files
+ cmd guilt select -n
+ cmd guilt select bar
+ cmd guilt guard -l
+-cmd guilt push -a
++cmd guilt push -a 2>&1 | grep -v "fatal: unrecognized input"
+ std_tests
+ cmd guilt pop -a
+ cmd list_files
diff --git a/guilt.spec b/guilt.spec
index c3f7256..d8bb122 100644
--- a/guilt.spec
+++ b/guilt.spec
@@ -1,6 +1,6 @@
 Name:		guilt
 Version:	0.35
-Release:	3%{?dist}
+Release:	4%{?dist}
 Summary:	Scripts to manage quilt-like patches on top of git
 
 Group:		Development/Tools
@@ -9,6 +9,8 @@ URL:		http://www.kernel.org/pub/linux/kernel/people/jsipek/%{name}/
 Source:		http://www.kernel.org/pub/linux/kernel/people/jsipek/%{name}/%{name}-%{version}.tar.bz2
 Requires:	git, gawk, sed, bash
 
+Patch0:		guilt-tests-git-workaround.patch
+
 BuildArch:	noarch
 BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 BuildRequires:	asciidoc, xmlto, git-core
@@ -24,6 +26,8 @@ made to your patches.
 %prep
 %setup -q
 
+%patch0 -p1
+
 %build
 make ASCIIDOC='asciidoc --unsafe' %{?_smp_mflags}
 
@@ -47,6 +51,9 @@ rm -rf $RPM_BUILD_ROOT
 %{_mandir}/man7/guilt*.7*
 
 %changelog
+* Fri Aug 03 2012 Eric Sandeen <sandeen at redhat.com> 0.35-4
+- Work around regression tests failures due to git change w.r.t. empty patches
+
 * Thu Jul 19 2012 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 0.35-3
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
 


More information about the scm-commits mailing list