[Libreoffice-commits] .: patches/dev300
Fridrich Strba
fridrich at kemper.freedesktop.org
Fri Nov 26 06:03:15 PST 2010
patches/dev300/apply | 3
patches/dev300/tools-qa-urlobj-unittest.diff | 300 ---------------------------
2 files changed, 303 deletions(-)
New commits:
commit 970e9b3ad3eb90346b90e43971e45a0aa1d27496
Author: Fridrich Å trba <fridrich.strba at bluewin.ch>
Date: Fri Nov 26 15:03:03 2010 +0100
tools-qa-urlobj-unittest.diff: migrated to git
n#261623
process relative SMB paths (in hyperlinks) correctly
diff --git a/patches/dev300/apply b/patches/dev300/apply
index af9e999..22fcc10 100755
--- a/patches/dev300/apply
+++ b/patches/dev300/apply
@@ -349,9 +349,6 @@ libxmlsec-olderlibxml2patch-fix.diff, jopsen
jpegc.c.diff, i#80674, n#272574, flr
[ Fixes ]
-# process relative SMB paths (in hyperlinks) correctly
-tools-qa-urlobj-unittest.diff, n#261623, flr
-
# check real help path defined in registry instead of the $(instpath)/help
sfx-check-real-help-path.diff, i#81139, pmladek
diff --git a/patches/dev300/tools-qa-urlobj-unittest.diff b/patches/dev300/tools-qa-urlobj-unittest.diff
deleted file mode 100644
index 6fb6228..0000000
--- a/patches/dev300/tools-qa-urlobj-unittest.diff
+++ /dev/null
@@ -1,300 +0,0 @@
----
- tools/qa/urlobj/export.map | 7 ++
- tools/qa/urlobj/makefile.mk | 72 ++++++++++++
- tools/qa/urlobj/tools_urlobj_test.cxx | 191 +++++++++++++++++++++++++++++++++
- 3 files changed, 270 insertions(+), 0 deletions(-)
- create mode 100644 tools/qa/urlobj/export.map
- create mode 100644 tools/qa/urlobj/makefile.mk
- create mode 100644 tools/qa/urlobj/tools_urlobj_test.cxx
-
-diff --git tools/qa/urlobj/export.map tools/qa/urlobj/export.map
-new file mode 100644
-index 0000000..8c1ebd8
---- /dev/null
-+++ tools/qa/urlobj/export.map
-@@ -0,0 +1,7 @@
-+ UDK_3.0 {
-+ global:
-+ registerAllTestFunction;
-+
-+ local:
-+ *;
-+ };
-diff --git tools/qa/urlobj/makefile.mk tools/qa/urlobj/makefile.mk
-new file mode 100644
-index 0000000..9eba6b2
---- /dev/null
-+++ tools/qa/urlobj/makefile.mk
-@@ -0,0 +1,72 @@
-+ #*************************************************************************
-+ #
-+ # OpenOffice.org - a multi-platform office productivity suite
-+ #
-+ # $RCSfile: makefile.mk,v $
-+ #
-+ # $Revision: 1.3 $
-+ #
-+ # last change: $Author: rt $ $Date: 2005/09/08 15:49:44 $
-+ #
-+ # The Contents of this file are made available subject to
-+ # the terms of GNU Lesser General Public License Version 2.1.
-+ #
-+ #
-+ # GNU Lesser General Public License Version 2.1
-+ # =============================================
-+ # Copyright 2005 by Sun Microsystems, Inc.
-+ # 901 San Antonio Road, Palo Alto, CA 94303, USA
-+ #
-+ # This library is free software; you can redistribute it and/or
-+ # modify it under the terms of the GNU Lesser General Public
-+ # License version 2.1, as published by the Free Software Foundation.
-+ #
-+ # This library is distributed in the hope that it will be useful,
-+ # but WITHOUT ANY WARRANTY; without even the implied warranty of
-+ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-+ # Lesser General Public License for more details.
-+ #
-+ # You should have received a copy of the GNU Lesser General Public
-+ # License along with this library; if not, write to the Free Software
-+ # Foundation, Inc., 59 Temple Place, Suite 330, Boston,
-+ # MA 02111-1307 USA
-+ #
-+ #*************************************************************************
-+ PRJ=..$/..
-+
-+ PRJNAME=tools
-+ TARGET=qa_tools_urlobj_test
-+ # this is removed at the moment because we need some enhancements
-+ # TESTDIR=TRUE
-+
-+ ENABLE_EXCEPTIONS=TRUE
-+
-+ # --- Settings -----------------------------------------------------
-+
-+ .INCLUDE : settings.mk
-+
-+ # BEGIN ----------------------------------------------------------------
-+ # auto generated Target:job by codegen.pl
-+ SHL1OBJS= \
-+ $(SLO)$/tools_urlobj_test.obj
-+
-+ SHL1TARGET= tools_urlobj
-+ SHL1STDLIBS=\
-+ $(SALLIB) \
-+ $(CPPUNITLIB) \
-+ $(TOOLSLIB)
-+
-+ SHL1IMPLIB= i$(SHL1TARGET)
-+ DEF1NAME =$(SHL1TARGET)
-+ SHL1VERSIONMAP= export.map
-+ # auto generated Target:job
-+ # END ------------------------------------------------------------------
-+
-+ #------------------------------- All object files -------------------------------
-+ # do this here, so we get right dependencies
-+ # SLOFILES=$(SHL1OBJS)
-+
-+ # --- Targets ------------------------------------------------------
-+
-+ .INCLUDE : target.mk
-+ .INCLUDE : _cppunit.mk
-diff --git tools/qa/urlobj/tools_urlobj_test.cxx tools/qa/urlobj/tools_urlobj_test.cxx
-new file mode 100644
-index 0000000..7ea1ccd
---- /dev/null
-+++ tools/qa/urlobj/tools_urlobj_test.cxx
-@@ -0,0 +1,191 @@
-+ /*************************************************************************
-+ *
-+ * OpenOffice.org - a multi-platform office productivity suite
-+ *
-+ * $RCSfile: $
-+ *
-+ * $Revision: $
-+ *
-+ * last change: $Author: $ $Date: $
-+ *
-+ * The Contents of this file are made available subject to
-+ * the terms of GNU Lesser General Public License Version 2.1.
-+ *
-+ *
-+ * GNU Lesser General Public License Version 2.1
-+ * =============================================
-+ * Copyright 2005 by Sun Microsystems, Inc.
-+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
-+ *
-+ * This library is free software; you can redistribute it and/or
-+ * modify it under the terms of the GNU Lesser General Public
-+ * License version 2.1, as published by the Free Software Foundation.
-+ *
-+ * This library is distributed in the hope that it will be useful,
-+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
-+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-+ * Lesser General Public License for more details.
-+ *
-+ * You should have received a copy of the GNU Lesser General Public
-+ * License along with this library; if not, write to the Free Software
-+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
-+ * MA 02111-1307 USA
-+ *
-+ ************************************************************************/
-+
-+ #include <cppunit/simpleheader.hxx>
-+
-+ #include <urlobj.hxx>
-+
-+ namespace tools_urlobj
-+ {
-+
-+ class urlobjTest : public CppUnit::TestFixture
-+ {
-+
-+ public:
-+ // initialise your test code values here.
-+ void setUp()
-+ {
-+ }
-+
-+ void tearDown()
-+ {
-+ }
-+
-+ // insert your test code here.
-+ // this is only demonstration code
-+ void urlobjTest_001()
-+ {
-+ INetURLObject aUrl(rtl::OUString::createFromAscii("file://10.10.1.1/sampledir/sample.file"));
-+ #ifdef LINUX
-+ CPPUNIT_ASSERT(aUrl.GetMainURL(INetURLObject::NO_DECODE).compareToAscii("smb://10.10.1.1/sampledir/sample.file")==0);
-+ CPPUNIT_ASSERT(aUrl.GetProtocol()==INET_PROT_SMB);
-+ #endif
-+ #ifdef WIN
-+ CPPUNIT_ASSERT(aUrl.GetMainURL(INetURLObject::NO_DECODE).compareToAscii("file://10.10.1.1/sampledir/sample.file")==0);
-+ CPPUNIT_ASSERT(aUrl.GetProtocol()==INET_PROT_FILE);
-+ #endif
-+ CPPUNIT_ASSERT(aUrl.GetHost(INetURLObject::NO_DECODE).compareToAscii("10.10.1.1")==0);
-+ CPPUNIT_ASSERT(aUrl.GetURLPath(INetURLObject::NO_DECODE).compareToAscii("/sampledir/sample.file")==0);
-+ CPPUNIT_ASSERT(aUrl.getName().compareToAscii("sample.file")==0);
-+ CPPUNIT_ASSERT(aUrl.getBase().compareToAscii("sample")==0);
-+ CPPUNIT_ASSERT(aUrl.getExtension().compareToAscii("file")==0);
-+ }
-+
-+ void urlobjTest_002()
-+ {
-+ INetURLObject aUrl;
-+ aUrl.setFSysPath(rtl::OUString::createFromAscii("\\\\137.65.170.24\\c$\\Img0001.jpg"), INetURLObject::FSYS_DETECT);
-+ #ifdef LINUX
-+ CPPUNIT_ASSERT(aUrl.GetMainURL(INetURLObject::NO_DECODE).compareToAscii("smb://137.65.170.24/c$/Img0001.jpg")==0);
-+ CPPUNIT_ASSERT(aUrl.GetProtocol()==INET_PROT_SMB);
-+ #endif
-+ #ifdef WIN
-+ CPPUNIT_ASSERT(aUrl.GetMainURL(INetURLObject::NO_DECODE).compareToAscii("file://137.65.170.24/c$/Img0001.jpg")==0);
-+ CPPUNIT_ASSERT(aUrl.GetProtocol()==INET_PROT_FILE);
-+ #endif
-+ CPPUNIT_ASSERT(aUrl.GetHost(INetURLObject::NO_DECODE).compareToAscii("137.65.170.24")==0);
-+ CPPUNIT_ASSERT(aUrl.GetURLPath(INetURLObject::NO_DECODE).compareToAscii("/c$/Img0001.jpg")==0);
-+ CPPUNIT_ASSERT(aUrl.getName().compareToAscii("Img0001.jpg")==0);
-+ CPPUNIT_ASSERT(aUrl.getBase().compareToAscii("Img0001")==0);
-+ CPPUNIT_ASSERT(aUrl.getExtension().compareToAscii("jpg")==0);
-+ }
-+
-+
-+ void urlobjTest_003()
-+ {
-+ INetURLObject aUrl;
-+ aUrl.setFSysPath(rtl::OUString::createFromAscii("\\\\hive-winxp-x86\\pmladek\\test2.odt"), INetURLObject::FSYS_DETECT);
-+ #ifdef LINUX
-+ CPPUNIT_ASSERT(aUrl.GetMainURL(INetURLObject::NO_DECODE).compareToAscii("smb://hive-winxp-x86/pmladek/test2.odt")==0);
-+ CPPUNIT_ASSERT(aUrl.GetProtocol()==INET_PROT_SMB);
-+ #endif
-+ #ifdef WIN
-+ CPPUNIT_ASSERT(aUrl.GetMainURL(INetURLObject::NO_DECODE).compareToAscii("file://hive-winxp-x86/pmladek/test2.odt")==0);
-+ CPPUNIT_ASSERT(aUrl.GetProtocol()==INET_PROT_FILE);
-+ #endif
-+ CPPUNIT_ASSERT(aUrl.GetHost(INetURLObject::NO_DECODE).compareToAscii("hive-winxp-x86")==0);
-+ CPPUNIT_ASSERT(aUrl.GetURLPath(INetURLObject::NO_DECODE).compareToAscii("/pmladek/test2.odt")==0);
-+ }
-+
-+ void urlobjTest_004()
-+ {
-+ INetURLObject aUrl(rtl::OUString::createFromAscii("smb://10.10.1.1/sampledir/sample.file"));
-+ #ifdef LINUX
-+ CPPUNIT_ASSERT(aUrl.GetMainURL(INetURLObject::NO_DECODE).compareToAscii("smb://10.10.1.1/sampledir/sample.file")==0);
-+ CPPUNIT_ASSERT(aUrl.GetProtocol()==INET_PROT_SMB);
-+ #endif
-+ #ifdef WIN
-+ CPPUNIT_ASSERT(aUrl.GetMainURL(INetURLObject::NO_DECODE).compareToAscii("file://10.10.1.1/sampledir/sample.file")==0);
-+ CPPUNIT_ASSERT(aUrl.GetProtocol()==INET_PROT_FILE);
-+ #endif
-+ CPPUNIT_ASSERT(aUrl.GetHost(INetURLObject::NO_DECODE).compareToAscii("10.10.1.1")==0);
-+ CPPUNIT_ASSERT(aUrl.GetURLPath(INetURLObject::NO_DECODE).compareToAscii("/sampledir/sample.file")==0);
-+ CPPUNIT_ASSERT(aUrl.getName().compareToAscii("sample.file")==0);
-+ CPPUNIT_ASSERT(aUrl.getBase().compareToAscii("sample")==0);
-+ CPPUNIT_ASSERT(aUrl.getExtension().compareToAscii("file")==0);
-+ }
-+
-+ void urlobjTest_005()
-+ {
-+ INetURLObject aUrl;
-+ aUrl.setFSysPath(rtl::OUString::createFromAscii("//137.65.170.24/c$/Img0001.jpg"), INetURLObject::FSYS_DETECT);
-+ #ifdef LINUX
-+ CPPUNIT_ASSERT(aUrl.GetMainURL(INetURLObject::NO_DECODE).compareToAscii("smb://137.65.170.24/c$/Img0001.jpg")==0);
-+ CPPUNIT_ASSERT(aUrl.GetProtocol()==INET_PROT_SMB);
-+ #endif
-+ #ifdef WIN
-+ CPPUNIT_ASSERT(aUrl.GetMainURL(INetURLObject::NO_DECODE).compareToAscii("file://137.65.170.24/c$/Img0001.jpg")==0);
-+ CPPUNIT_ASSERT(aUrl.GetProtocol()==INET_PROT_FILE);
-+ #endif
-+ CPPUNIT_ASSERT(aUrl.GetHost(INetURLObject::NO_DECODE).compareToAscii("137.65.170.24")==0);
-+ CPPUNIT_ASSERT(aUrl.GetURLPath(INetURLObject::NO_DECODE).compareToAscii("/c$/Img0001.jpg")==0);
-+ CPPUNIT_ASSERT(aUrl.getName().compareToAscii("Img0001.jpg")==0);
-+ CPPUNIT_ASSERT(aUrl.getBase().compareToAscii("Img0001")==0);
-+ CPPUNIT_ASSERT(aUrl.getExtension().compareToAscii("jpg")==0);
-+ }
-+
-+
-+ void urlobjTest_006()
-+ {
-+ INetURLObject aUrl;
-+ aUrl.setFSysPath(rtl::OUString::createFromAscii("//hive-winxp-x86/pmladek/test2.odt"), INetURLObject::FSYS_DETECT);
-+ #ifdef LINUX
-+ CPPUNIT_ASSERT(aUrl.GetMainURL(INetURLObject::NO_DECODE).compareToAscii("smb://hive-winxp-x86/pmladek/test2.odt")==0);
-+ CPPUNIT_ASSERT(aUrl.GetProtocol()==INET_PROT_SMB);
-+ #endif
-+ #ifdef WIN
-+ CPPUNIT_ASSERT(aUrl.GetMainURL(INetURLObject::NO_DECODE).compareToAscii("file://hive-winxp-x86/pmladek/test2.odt")==0);
-+ CPPUNIT_ASSERT(aUrl.GetProtocol()==INET_PROT_FILE);
-+ #endif
-+ CPPUNIT_ASSERT(aUrl.GetHost(INetURLObject::NO_DECODE).compareToAscii("hive-winxp-x86")==0);
-+ CPPUNIT_ASSERT(aUrl.GetURLPath(INetURLObject::NO_DECODE).compareToAscii("/pmladek/test2.odt")==0);
-+ }
-+
-+
-+
-+ // Change the following lines only, if you add, remove or rename
-+ // member functions of the current class,
-+ // because these macros are need by auto register mechanism.
-+
-+ CPPUNIT_TEST_SUITE(urlobjTest);
-+ CPPUNIT_TEST(urlobjTest_001);
-+ CPPUNIT_TEST(urlobjTest_002);
-+ CPPUNIT_TEST(urlobjTest_003);
-+ CPPUNIT_TEST(urlobjTest_004);
-+ CPPUNIT_TEST(urlobjTest_005);
-+ CPPUNIT_TEST(urlobjTest_006);
-+ CPPUNIT_TEST_SUITE_END();
-+ }; // class createPool
-+
-+
-+ CPPUNIT_TEST_SUITE_NAMED_REGISTRATION(tools_urlobj::urlobjTest, "tools_urlobj");
-+ } // namespace rtl_random
-+
-+
-+ // -----------------------------------------------------------------------------
-+
-+ // this macro creates an empty function, which will called by the RegisterAllFunctions()
-+ // to let the user the possibility to also register some functions by hand.
-+ NOADDITIONAL;
---
-1.7.0.1
-
More information about the Libreoffice-commits
mailing list