[texstudio] fix the build for the testcases

hannes hannes at fedoraproject.org
Wed Feb 15 22:43:56 UTC 2012


commit f4bee623515043b87afb457d8ca1bd37f9e4abae
Author: hannes <hannes at fedoraproject.org>
Date:   Wed Feb 15 22:44:04 2012 +0000

    fix the build for the testcases

 texstudio-2.3-testcase.patch |   15 +++++++++++++++
 texstudio.spec               |    2 ++
 2 files changed, 17 insertions(+), 0 deletions(-)
---
diff --git a/texstudio-2.3-testcase.patch b/texstudio-2.3-testcase.patch
new file mode 100644
index 0000000..da87fd3
--- /dev/null
+++ b/texstudio-2.3-testcase.patch
@@ -0,0 +1,15 @@
+--- a/tests/qsearchreplacepanel_t.cpp	2012/01/23 01:30:39	2413
++++ b/tests/qsearchreplacepanel_t.cpp	2012/02/15 21:59:09	2551
+@@ -213,9 +213,9 @@
+ 				widget->cFind->lineEdit()->cursorForward(false,search.length());	
+ 				QTest::keyClick(widget->cFind->lineEdit(),search[search.length()-1].toLatin1());
+ 			}
+-			QDocumentCursor s=ed->cursor().selectionStart();
+-			QEQUAL2(s.lineNumber(), cy, search+" "+ed->cursor().selectedText()+"  "+QString::number(loop));
+-			QEQUAL2(s.columnNumber(), cx, search+" "+ed->cursor().selectedText());
++			QDocumentCursor c=ed->cursor().selectionStart();
++			QEQUAL2(c.lineNumber(), cy, search+" "+ed->cursor().selectedText()+"  "+QString::number(loop));
++			QEQUAL2(c.columnNumber(), cx, search+" "+ed->cursor().selectedText());
+ 			QEQUAL2(ed->cursor().selectedText(), res, search+" "+ed->cursor().selectedText());
+ 			//searching shouldn't change highlighted selection
+ 			QCEMULTIEQUAL(getHighlightedSelection(ed), panel->getSearchScope(), ed->document()->cursor(scopey1,scopex1,scopey2,scopex2));	
diff --git a/texstudio.spec b/texstudio.spec
index 0bb387b..e91faf9 100644
--- a/texstudio.spec
+++ b/texstudio.spec
@@ -15,6 +15,7 @@ Patch0:         texstudio-use-system-hunspell-instead-of-bundled-one.patch
 Patch1:         texstudio-use-system-qtsingleapplication-instead-of-bundled-on.patch
 Patch2:         texstudio-viewers-use-xdg-open.patch
 Patch3:         texstudio-2.3-gcc-4.7-build-failure.patch
+Patch4:         texstudio-2.3-testcase.patch
 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
 BuildRequires:  qt4-devel
@@ -47,6 +48,7 @@ so it keeps it look&feel.
 %patch1 -p0 -b .qtsingle
 %patch2 -p0 -b .xdg
 %patch3 -p0 -b .gcc4.7
+%patch4 -p0 -b .testcase
 
 rm -rf {hunspell,qtsingleapplication}
 


More information about the scm-commits mailing list