Kaydet (Commit) 7d1bb036 authored tarafından Stephan Bergmann's avatar Stephan Bergmann

Simplified setting headless mode for smoke-/subsequenttetss.

Both C++ and Java OfficeConnection code now always pass --headless, so no
need for SAL_USE_VCLPLUGIN=svp etc. any more.  Only some C++ unit tests that
link against vcl still need an explicit --headless.
üst bf0a3add
...@@ -36,7 +36,6 @@ distro-pack-install: install ...@@ -36,7 +36,6 @@ distro-pack-install: install
dev-install:|all dev-install:|all
@. ./Env.Host.sh && \ @. ./Env.Host.sh && \
cd smoketestoo_native && \ cd smoketestoo_native && \
export SAL_USE_VCLPLUGIN="svp" && \
build.pl -P@BUILD_NCPUS@ --all:instsetoo_native -- -P@BUILD_MAX_JOBS@ && \ build.pl -P@BUILD_NCPUS@ --all:instsetoo_native -- -P@BUILD_MAX_JOBS@ && \
cd @abs_builddir@ && ln -s $$SOLARVER/$$INPATH/installation/opt/ install && \ cd @abs_builddir@ && ln -s $$SOLARVER/$$INPATH/installation/opt/ install && \
echo "" && \ echo "" && \
...@@ -94,7 +93,6 @@ Makefile: autogen.lastrun configure.in ooo.lst.in set_soenv.in Makefile.in ...@@ -94,7 +93,6 @@ Makefile: autogen.lastrun configure.in ooo.lst.in set_soenv.in Makefile.in
check: Makefile dmake/dmake@EXEEXT_FOR_BUILD@ fetch check: Makefile dmake/dmake@EXEEXT_FOR_BUILD@ fetch
@. ./Env.Host.sh && \ @. ./Env.Host.sh && \
cd smoketestoo_native && \ cd smoketestoo_native && \
export SAL_USE_VCLPLUGIN="svp" && \
build.pl -P@BUILD_NCPUS@ --all -- -P@BUILD_MAX_JOBS@ build.pl -P@BUILD_NCPUS@ --all -- -P@BUILD_MAX_JOBS@
@. ./Env.Host.sh && $(MAKE) -f "$$SRC_ROOT"/GNUmakefile.mk -r \ @. ./Env.Host.sh && $(MAKE) -f "$$SRC_ROOT"/GNUmakefile.mk -r \
$(if @VERBOSE@,,-s) --jobs="$(if \ $(if @VERBOSE@,,-s) --jobs="$(if \
......
...@@ -66,8 +66,6 @@ $(eval $(call gb_CppunitTest_add_service_rdbs,hwpfilter_test_hwpfilter,\ ...@@ -66,8 +66,6 @@ $(eval $(call gb_CppunitTest_add_service_rdbs,hwpfilter_test_hwpfilter,\
)) ))
$(eval $(call gb_CppunitTest_set_args,hwpfilter_test_hwpfilter,\ $(eval $(call gb_CppunitTest_set_args,hwpfilter_test_hwpfilter,\
--headless \
--invisible \
--protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \ --protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \
)) ))
......
...@@ -60,8 +60,7 @@ $(eval $(call gb_CppunitTest_add_service_rdbs,i18npool_test_breakiterator,\ ...@@ -60,8 +60,7 @@ $(eval $(call gb_CppunitTest_add_service_rdbs,i18npool_test_breakiterator,\
)) ))
$(eval $(call gb_CppunitTest_set_args,i18npool_test_breakiterator,\ $(eval $(call gb_CppunitTest_set_args,i18npool_test_breakiterator,\
--headless \ --protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \
--invisible \
)) ))
$(eval $(call gb_RdbTarget_RdbTarget,i18npool_test_breakiterator)) $(eval $(call gb_RdbTarget_RdbTarget,i18npool_test_breakiterator))
......
...@@ -67,7 +67,6 @@ $(eval $(call gb_CppunitTest_add_service_rdbs,lotuswordpro_test_lotuswordpro,\ ...@@ -67,7 +67,6 @@ $(eval $(call gb_CppunitTest_add_service_rdbs,lotuswordpro_test_lotuswordpro,\
$(eval $(call gb_CppunitTest_set_args,lotuswordpro_test_lotuswordpro,\ $(eval $(call gb_CppunitTest_set_args,lotuswordpro_test_lotuswordpro,\
--headless \ --headless \
--invisible \
--protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \ --protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \
)) ))
......
...@@ -92,8 +92,6 @@ $(eval $(call gb_CppunitTest_add_service_rdbs,sc_filters_test,\ ...@@ -92,8 +92,6 @@ $(eval $(call gb_CppunitTest_add_service_rdbs,sc_filters_test,\
)) ))
$(eval $(call gb_CppunitTest_set_args,sc_filters_test,\ $(eval $(call gb_CppunitTest_set_args,sc_filters_test,\
--headless \
--invisible \
--protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \ --protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \
-env:OOO_CONFIG_REGISTRY_DIR=$(call gb_CppunitTarget__make_url,$(OUTDIR)/xml/registry) \ -env:OOO_CONFIG_REGISTRY_DIR=$(call gb_CppunitTarget__make_url,$(OUTDIR)/xml/registry) \
)) ))
......
...@@ -98,7 +98,6 @@ $(eval $(call gb_CppunitTest_add_service_rdbs,sc_ucalc,\ ...@@ -98,7 +98,6 @@ $(eval $(call gb_CppunitTest_add_service_rdbs,sc_ucalc,\
$(eval $(call gb_CppunitTest_set_args,sc_ucalc,\ $(eval $(call gb_CppunitTest_set_args,sc_ucalc,\
--headless \ --headless \
--invisible \
--protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \ --protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \
)) ))
......
...@@ -92,7 +92,6 @@ $(eval $(call gb_CppunitTest_add_service_rdbs,sd_uimpress,\ ...@@ -92,7 +92,6 @@ $(eval $(call gb_CppunitTest_add_service_rdbs,sd_uimpress,\
$(eval $(call gb_CppunitTest_set_args,sd_uimpress,\ $(eval $(call gb_CppunitTest_set_args,sd_uimpress,\
--headless \ --headless \
--invisible \
--protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \ --protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \
)) ))
......
...@@ -438,7 +438,6 @@ def verify_smoketest(): ...@@ -438,7 +438,6 @@ def verify_smoketest():
arc = p[2] arc = p[2]
if s == "Linux": if s == "Linux":
os.environ['SAL_USE_VCLPLUGIN'] = "svp"
os.environ['LD_LIBRARY_PATH'] = "" os.environ['LD_LIBRARY_PATH'] = ""
os.environ['LD_LIBRARY_PATH'] = ':'.join([os.path.join(root_dir, 'lib'), INSTALL_DIR + '/opt/libreoffice' + build_version + '/ure/lib', os.environ['LD_LIBRARY_PATH']]) os.environ['LD_LIBRARY_PATH'] = ':'.join([os.path.join(root_dir, 'lib'), INSTALL_DIR + '/opt/libreoffice' + build_version + '/ure/lib', os.environ['LD_LIBRARY_PATH']])
cmd_cppu = [ cmd_cppu = [
......
...@@ -30,7 +30,6 @@ ...@@ -30,7 +30,6 @@
# JunitTest class # JunitTest class
gb_JunitTest_JAVACOMMAND := $(JAVAINTERPRETER) $(JAVAIFLAGS) gb_JunitTest_JAVACOMMAND := $(JAVAINTERPRETER) $(JAVAIFLAGS)
gb_JunitTest_HEADLESS := $(true)
# in non-product builds, ensure that tools-based assertions do not pop up as message box, but are routed to the shell # in non-product builds, ensure that tools-based assertions do not pop up as message box, but are routed to the shell
DBGSV_ERROR_OUT := shell DBGSV_ERROR_OUT := shell
...@@ -51,8 +50,6 @@ $(call gb_JunitTest_get_target,%) : ...@@ -51,8 +50,6 @@ $(call gb_JunitTest_get_target,%) :
mkdir -p $(call gb_JunitTest_get_userdir,$*) && \ mkdir -p $(call gb_JunitTest_get_userdir,$*) && \
($(gb_JunitTest_JAVACOMMAND) \ ($(gb_JunitTest_JAVACOMMAND) \
-cp "$(CLASSPATH)" \ -cp "$(CLASSPATH)" \
$(if $(strip $(gb_JunitTest_HEADLESS)),\
-Dorg.openoffice.test.arg.headless=$(gb_JunitTest_HEADLESS)) \
$(if $(strip $(gb_JunitTest_DEBUGCOMMAND)),\ $(if $(strip $(gb_JunitTest_DEBUGCOMMAND)),\
'-Dorg.openoffice.test.arg.debugcommand=$(gb_JunitTest_DEBUGCOMMAND)') \ '-Dorg.openoffice.test.arg.debugcommand=$(gb_JunitTest_DEBUGCOMMAND)') \
$(DEFS) \ $(DEFS) \
......
...@@ -89,8 +89,6 @@ $(eval $(call gb_CppunitTest_add_service_rdbs,starmath_qa_cppunit,\ ...@@ -89,8 +89,6 @@ $(eval $(call gb_CppunitTest_add_service_rdbs,starmath_qa_cppunit,\
)) ))
$(eval $(call gb_CppunitTest_set_args,starmath_qa_cppunit,\ $(eval $(call gb_CppunitTest_set_args,starmath_qa_cppunit,\
--headless \
--invisible \
--protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \ --protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \
)) ))
......
...@@ -63,7 +63,6 @@ $(eval $(call gb_CppunitTest_add_type_rdbs,svtools_filters_test,\ ...@@ -63,7 +63,6 @@ $(eval $(call gb_CppunitTest_add_type_rdbs,svtools_filters_test,\
$(eval $(call gb_CppunitTest_set_args,svtools_filters_test,\ $(eval $(call gb_CppunitTest_set_args,svtools_filters_test,\
--headless \ --headless \
--invisible \
--protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \ --protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \
)) ))
......
...@@ -101,7 +101,6 @@ $(call gb_CppunitTest_get_target,sw_swdoc_test) : \ ...@@ -101,7 +101,6 @@ $(call gb_CppunitTest_get_target,sw_swdoc_test) : \
$(eval $(call gb_CppunitTest_set_args,sw_swdoc_test,\ $(eval $(call gb_CppunitTest_set_args,sw_swdoc_test,\
--headless \ --headless \
--invisible \
--protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \ --protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \
)) ))
......
...@@ -77,8 +77,6 @@ $(eval $(call gb_CppunitTest_add_service_rdbs,sw_filters_test,\ ...@@ -77,8 +77,6 @@ $(eval $(call gb_CppunitTest_add_service_rdbs,sw_filters_test,\
)) ))
$(eval $(call gb_CppunitTest_set_args,sw_filters_test,\ $(eval $(call gb_CppunitTest_set_args,sw_filters_test,\
--headless \
--invisible \
--protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \ --protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \
)) ))
......
...@@ -74,8 +74,10 @@ void OfficeConnection::setUp() { ...@@ -74,8 +74,10 @@ void OfficeConnection::setUp() {
rtl::OUString nofirstArg( rtl::OUString nofirstArg(
RTL_CONSTASCII_USTRINGPARAM("--nofirststartwizard")); RTL_CONSTASCII_USTRINGPARAM("--nofirststartwizard"));
rtl::OUString norestoreArg(RTL_CONSTASCII_USTRINGPARAM("--norestore")); rtl::OUString norestoreArg(RTL_CONSTASCII_USTRINGPARAM("--norestore"));
//Disable use of the unix standalone splash screen app for the tests rtl::OUString nologoArg(RTL_CONSTASCII_USTRINGPARAM("--nologo"));
rtl::OUString noSplashArg(RTL_CONSTASCII_USTRINGPARAM("--nologo")); // disable use of the unix standalone splash screen app for the
// tests (probably not needed in combination with --headless?)
rtl::OUString headlessArg(RTL_CONSTASCII_USTRINGPARAM("--headless"));
rtl::OUString acceptArg( rtl::OUString acceptArg(
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("--accept=")) + desc + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("--accept=")) + desc +
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(";urp"))); rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(";urp")));
...@@ -93,8 +95,9 @@ void OfficeConnection::setUp() { ...@@ -93,8 +95,9 @@ void OfficeConnection::setUp() {
RTL_CONSTASCII_USTRINGPARAM( RTL_CONSTASCII_USTRINGPARAM(
"-env:UNO_JAVA_JFW_ENV_CLASSPATH=true")); "-env:UNO_JAVA_JFW_ENV_CLASSPATH=true"));
rtl_uString * args[] = { rtl_uString * args[] = {
noquickArg.pData, nofirstArg.pData, norestoreArg.pData, noSplashArg.pData, noquickArg.pData, nofirstArg.pData, norestoreArg.pData,
acceptArg.pData, userArg.pData, jreArg.pData, classpathArg.pData }; nologoArg.pData, headlessArg.pData, acceptArg.pData, userArg.pData,
jreArg.pData, classpathArg.pData };
rtl_uString ** envs = 0; rtl_uString ** envs = 0;
rtl::OUString argEnv; rtl::OUString argEnv;
if (detail::getArgument( if (detail::getArgument(
...@@ -107,8 +110,8 @@ void OfficeConnection::setUp() { ...@@ -107,8 +110,8 @@ void OfficeConnection::setUp() {
osl_executeProcess( osl_executeProcess(
toAbsoluteFileUrl( toAbsoluteFileUrl(
argSoffice.copy(RTL_CONSTASCII_LENGTH("path:"))).pData, argSoffice.copy(RTL_CONSTASCII_LENGTH("path:"))).pData,
args, SAL_N_ELEMENTS( args ), 0, 0, 0, envs, args, SAL_N_ELEMENTS(args), 0, 0, 0, envs, envs == 0 ? 0 : 1,
envs == 0 ? 0 : 1, &process_)); &process_));
} else if (argSoffice.matchAsciiL(RTL_CONSTASCII_STRINGPARAM("connect:"))) { } else if (argSoffice.matchAsciiL(RTL_CONSTASCII_STRINGPARAM("connect:"))) {
desc = argSoffice.copy(RTL_CONSTASCII_LENGTH("connect:")); desc = argSoffice.copy(RTL_CONSTASCII_LENGTH("connect:"));
} else { } else {
......
...@@ -53,20 +53,13 @@ public final class OfficeConnection { ...@@ -53,20 +53,13 @@ public final class OfficeConnection {
public void setUp() throws Exception { public void setUp() throws Exception {
String sofficeArg = Argument.get("soffice"); String sofficeArg = Argument.get("soffice");
if (sofficeArg.startsWith("path:")) { if (sofficeArg.startsWith("path:")) {
String headless_flags = "";
try {
if(Argument.get("headless").length() > 0) {
headless_flags = "--headless";
}
} catch(Exception e) {}
description = "pipe,name=oootest" + UUID.randomUUID(); description = "pipe,name=oootest" + UUID.randomUUID();
ProcessBuilder pb = new ProcessBuilder( ProcessBuilder pb = new ProcessBuilder(
sofficeArg.substring("path:".length()), "--quickstart=no", sofficeArg.substring("path:".length()), "--quickstart=no",
"--nofirststartwizard", "--norestore", "--nologo", "--nofirststartwizard", "--norestore", "--nologo", "--headless",
"--accept=" + description + ";urp", "--accept=" + description + ";urp",
"-env:UserInstallation=" + Argument.get("user"), "-env:UserInstallation=" + Argument.get("user"),
"-env:UNO_JAVA_JFW_ENV_JREHOME=true", "-env:UNO_JAVA_JFW_ENV_JREHOME=true");
headless_flags);
String envArg = Argument.get("env"); String envArg = Argument.get("env");
if (envArg != null) { if (envArg != null) {
Map<String, String> env = pb.environment(); Map<String, String> env = pb.environment();
......
...@@ -61,8 +61,6 @@ $(eval $(call gb_CppunitTest_add_service_rdbs,writerfilter_rtftok,\ ...@@ -61,8 +61,6 @@ $(eval $(call gb_CppunitTest_add_service_rdbs,writerfilter_rtftok,\
)) ))
$(eval $(call gb_CppunitTest_set_args,writerfilter_rtftok,\ $(eval $(call gb_CppunitTest_set_args,writerfilter_rtftok,\
--headless \
--invisible \
--protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \ --protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \
)) ))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment