summaryrefslogtreecommitdiff
path: root/solenv
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2018-03-02 11:14:29 +0100
committerStephan Bergmann <sbergman@redhat.com>2018-03-02 14:21:08 +0100
commit35c4650ef871fd0fd3baba409d6219c8c6c3cb44 (patch)
treed703ae4afa04fe0ae4251bb8032075cd300e676f /solenv
parent1a731e502be698132d3063f2eebde23f8ac98b4c (diff)
Restrict UITest SAL_LOG_FILE hack to Windows
...where it appears to be necessary, as the subprocess.Popen in uitest/libreoffice/connection.py apparently doesn't manage to make the spawned soffice process send stdout/-err output to the python process's stdout/-err (as works fine e.g. on Linux). (Only using that hack on Windows has the advantage that on other platforms output from the python and the soffice process will be properly interspersed. On Windows, at least sal/log.hxx messages from the soffice process are captured that way, while its stdout/-err output is still lost.) Also dump the soffice.out.log content in case of failure. (Note that, despite the file's name, it contains any sal/log.hxx messages from both the python and the soffice process.) Change-Id: Ic99a62b1abbe2fbbf98128a35203e2fd05335266 Reviewed-on: https://gerrit.libreoffice.org/50620 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'solenv')
-rw-r--r--solenv/gbuild/UITest.mk6
1 files changed, 5 insertions, 1 deletions
diff --git a/solenv/gbuild/UITest.mk b/solenv/gbuild/UITest.mk
index cebb030a12cd..10bddcb677cf 100644
--- a/solenv/gbuild/UITest.mk
+++ b/solenv/gbuild/UITest.mk
@@ -63,7 +63,7 @@ else
$(if $(G_SLICE),G_SLICE=$(G_SLICE)) \
$(if $(GLIBCXX_FORCE_NEW),GLIBCXX_FORCE_NEW=$(GLIBCXX_FORCE_NEW)) \
$(DEFS) \
- SAL_LOG_FILE="$(dir $(call gb_UITest_get_target,$*))/soffice.out.log" \
+ $(if $(filter WNT,$(OS)),SAL_LOG_FILE="$(dir $(call gb_UITest_get_target,$*))/soffice.out.log") \
TEST_LIB=$(call gb_Library_get_target,test) \
URE_BOOTSTRAP=vnd.sun.star.pathname:$(call gb_Helper_get_rcfile,$(INSTROOT)/$(LIBO_ETC_FOLDER)/fundamental) \
PYTHONPATH="$(PYPATH)" \
@@ -82,6 +82,10 @@ else
|| ($(if $(value gb_CppunitTest_postprocess), \
RET=$$?; \
$(call gb_CppunitTest_postprocess,$(gb_UITest_EXECUTABLE_GDB),$@.core,$$RET) >> $@.log 2>&1;) \
+ $(if $(filter WNT,$(OS)), \
+ printf '%s: <<<\n' $(dir $(call gb_UITest_get_target,$*))/soffice.out.log; \
+ cat $(dir $(call gb_UITest_get_target,$*))/soffice.out.log; \
+ printf ' >>>\n\n';) \
cat $@.log; $(gb_UITest_UNITTESTFAILED) UI $*))))
endif