[Libreoffice-commits] .: 3 commits - svl/qa
Caolán McNamara
caolan at kemper.freedesktop.org
Fri Jan 14 08:34:00 PST 2011
svl/qa/export.map | 2 -
svl/qa/makefile.mk | 87 ++++++++++++++++++++++------------------------
svl/qa/test_URIHelper.cxx | 19 ++++++++--
3 files changed, 60 insertions(+), 48 deletions(-)
New commits:
commit 8c11fbe7a722fc8dc604f30b2df9565eba389d90
Author: Caolán McNamara <caolanm at redhat.com>
Date: Fri Jan 14 16:32:49 2011 +0000
cppunit: make these tests work again
diff --git a/svl/qa/makefile.mk b/svl/qa/makefile.mk
index b4444f5..6be2ee7 100644
--- a/svl/qa/makefile.mk
+++ b/svl/qa/makefile.mk
@@ -59,9 +59,42 @@ SHL1STDLIBS=\
SHL1IMPLIB=i$(SHL1TARGET)
DEF1NAME=$(SHL1TARGET)
-SHL1VERSIONMAP= export.map
+SHL1VERSIONMAP=export.map
# --- Targets ------------------------------------------------------
.INCLUDE : target.mk
-.INCLUDE : _cppunit.mk
+
+.IF "$(OS)" == "WNT"
+my_file = file:///
+.ELSE
+my_file = file://
+.END
+
+ALLTAR: test
+
+$(MISC)$/$(TARGET)$/types.rdb .ERRREMOVE : $(SOLARBINDIR)$/types.rdb
+ $(MKDIRHIER) $(@:d)
+ $(GNUCOPY) $? $@
+
+$(MISC)/$(TARGET)/udkapi.rdb .ERRREMOVE : $(SOLARBINDIR)$/udkapi.rdb
+ $(MKDIRHIER) $(@:d)
+ $(GNUCOPY) $? $@
+
+#Make a services.rdb with the services we know we need to get up and running
+$(MISC)/$(TARGET)/services.rdb .ERRREMOVE : $(MISC)/$(TARGET)/udkapi.rdb makefile.mk
+ $(MKDIRHIER) $(@:d)
+ $(REGCOMP) -register -br $(MISC)/$(TARGET)/udkapi.rdb -r $@ -wop \
+ -c $(DLLPRE)ucb1$(DLLPOST) \
+ -c stocservices.uno$(DLLPOST)
+
+test .PHONY: $(SHL1TARGETN) $(MISC)/$(TARGET)/services.rdb $(MISC)$/$(TARGET)$/types.rdb $(MISC)/$(TARGET)/udkapi.rdb
+ @echo ----------------------------------------------------------
+ @echo - start unit test \#1 on library $(SHL1TARGETN)
+ @echo ----------------------------------------------------------
+ $(CPPUNITTESTER) $(SHL1TARGETN) -headless -invisible \
+ -env:UNO_SERVICES=$(my_file)$(PWD)/$(MISC)/$(TARGET)/services.rdb \
+ -env:UNO_TYPES="$(my_file)$(PWD)/$(MISC)/$(TARGET)/types.rdb $(my_file)$(PWD)/$(MISC)/$(TARGET)/udkapi.rdb" \
+ -env:OOO_BASE_DIR="$(my_file)$(PWD)/$(MISC)/$(TARGET)" \
+ -env:BRAND_BASE_DIR="$(my_file)$(PWD)/$(MISC)/$(TARGET)" \
+ -env:UNO_USER_PACKAGES_CACHE="$(my_file)$(PWD)/$(MISC)/$(TARGET)"
commit eb75f8ff5a2d20d15357d31b2b32aa43c9c3972e
Author: Caolán McNamara <caolanm at redhat.com>
Date: Fri Jan 14 16:20:34 2011 +0000
sync test with da0fd5c999fc6f8b5e2d4ecccbf66e1034a03ed9
diff --git a/svl/qa/test_URIHelper.cxx b/svl/qa/test_URIHelper.cxx
index 44aad83..3f86000 100644
--- a/svl/qa/test_URIHelper.cxx
+++ b/svl/qa/test_URIHelper.cxx
@@ -344,7 +344,13 @@ void Test::testFindFirstURLInText() {
"ftp://bla.bla.bla/blubber/", 3, 29 },
{ "..\\ftp://bla.bla.bla/blubber/...", 0, 0, 0 },
{ "..\\ftp:\\\\bla.bla.bla\\blubber/...",
+//Sync with tools/source/fsys/urlobj.cxx and changeScheme
+#ifdef LINUX
+ "smb://bla.bla.bla/blubber%2F", 7, 29 },
+#endif
+#ifdef WNT
"file://bla.bla.bla/blubber%2F", 7, 29 },
+#endif
{ "http://sun.com", "http://sun.com/", 0, 14 },
{ "http://sun.com/", "http://sun.com/", 0, 15 },
{ "http://www.xerox.com@www.pcworld.com/go/3990332.htm", 0, 0, 0 },
commit e6a564af05833b74dc725f12a4b6dd2688f0f5a1
Author: Caolán McNamara <caolanm at redhat.com>
Date: Fri Jan 14 16:19:25 2011 +0000
get these tests building again
diff --git a/svl/qa/export.map b/svl/qa/export.map
index f313c44..0dbbcc5 100644
--- a/svl/qa/export.map
+++ b/svl/qa/export.map
@@ -27,7 +27,7 @@
UDK_3_0_0 {
global:
- registerAllTestFunction;
+ cppunitTestPlugIn;
local:
*;
diff --git a/svl/qa/makefile.mk b/svl/qa/makefile.mk
index 7e8c7ee..b4444f5 100644
--- a/svl/qa/makefile.mk
+++ b/svl/qa/makefile.mk
@@ -35,10 +35,14 @@ ENABLE_EXCEPTIONS = true
.INCLUDE : settings.mk
-CFLAGSCXX += $(CPPUNIT_CFLAGS)
+#building with stlport, but cppunit was not built with stlport
+.IF "$(USE_SYSTEM_STL)"!="YES"
+.IF "$(SYSTEM_CPPUNIT)"=="YES"
+CFLAGSCXX+=-DADAPT_EXT_STL
+.ENDIF
+.ENDIF
+CFLAGSCXX+=$(CPPUNIT_CFLAGS)
-# BEGIN ----------------------------------------------------------------
-# auto generated Target:job by codegen.pl
SHL1OBJS= \
$(SLO)$/test_URIHelper.obj
@@ -53,49 +57,11 @@ SHL1STDLIBS=\
$(TESTSHL2LIB) \
$(CPPUNITLIB)
-SHL1IMPLIB= i$(SHL1TARGET)
-DEF1NAME =$(SHL1TARGET)
+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
-
-# LLA: old stuff
-# USE_DEFFILE = true
-#
-# .INCLUDE: settings.mk
-#
-# .IF "$(OS)" == "WNT"
-# REGEXP = "s/^[\#].*$$//"
-# .ELSE # OS, WNT
-# REGEXP = 's/^[\#].*$$//'
-# .ENDIF # OS, WNT
-#
-# SHL1TARGET = URIHelper
-# SHL1OBJS = \
-# $(SLO)$/test_URIHelper.obj
-# SHL1STDLIBS = \
-# $(CPPULIB) \
-# $(CPPUHELPERLIB) \
-# $(SALLIB) \
-# $(SVTOOLLIB) \
-# $(TOOLSLIB) \
-# $(UNOTOOLSLIB)
-#
-# DEF1NAME = $(SHL1TARGET)
-# DEF1EXPORTFILE = $(MISC)$/$(SHL1TARGET).dxp
-#
-# .INCLUDE: target.mk
-#
-# $(MISC)$/$(SHL1TARGET).dxp: sce$/$(SHL1TARGET).sce
-# + $(TYPE) $< | sed $(REGEXP) > $@
-# + $(TYPE) $@ | sed "s/^/test_/" > $(MISC)$/$(SHL1TARGET).tst
-# + $(TYPE) $(MISC)$/$(SHL1TARGET).tst | sed "/test_./ w $@"
diff --git a/svl/qa/test_URIHelper.cxx b/svl/qa/test_URIHelper.cxx
index 5d548f9..44aad83 100644
--- a/svl/qa/test_URIHelper.cxx
+++ b/svl/qa/test_URIHelper.cxx
@@ -31,6 +31,14 @@
#include "sal/config.h"
+#include "preextstl.h"
+#include <cppunit/TestSuite.h>
+#include <cppunit/TestFixture.h>
+#include <cppunit/TestCase.h>
+#include <cppunit/plugin/TestPlugIn.h>
+#include <cppunit/extensions/HelperMacros.h>
+#include "postextstl.h"
+
#include <cstddef>
#include "com/sun/star/lang/Locale.hpp"
@@ -55,7 +63,6 @@
#include "cppuhelper/bootstrap.hxx"
#include "cppuhelper/implbase1.hxx"
#include "cppuhelper/implbase2.hxx"
-#include "testshl/simpleheader.hxx"
#include "osl/diagnose.h"
#include "rtl/strbuf.hxx"
#include "rtl/string.h"
@@ -454,10 +461,10 @@ void Test::testFindFirstURLInText() {
css::uno::Reference< css::uno::XComponentContext > Test::m_context;
-CPPUNIT_TEST_SUITE_NAMED_REGISTRATION(Test, "alltests");
+CPPUNIT_TEST_SUITE_REGISTRATION(Test);
}
-NOADDITIONAL;
+CPPUNIT_PLUGIN_IMPLEMENT();
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
More information about the Libreoffice-commits
mailing list