uitest/libreoffice/connection.py | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-)
New commits: commit 43aef04d77aafb9d055957642e62b559231f3711 Author: Stephan Bergmann <sberg...@redhat.com> AuthorDate: Fri Oct 4 08:29:06 2019 +0200 Commit: Stephan Bergmann <sberg...@redhat.com> CommitDate: Fri Oct 4 09:59:15 2019 +0200 Reliably wait for soffice to terminate ...to avoid leftover soffice-related processes (oosplash, soffice.bin) from UITests, whose occasional presence on tinderboxes is discussed in the comments to <https://gerrit.libreoffice.org/#/c/79854/> "uitest: make child soffice process die when parent dies". Should sucha an soffice-related process fail to terminate, the UITest will now fail to terminate too, and (a) a developer can debug the hung processes or (b) a tinderbox can reliably kill all processes (cf. <https://gerrit.libreoffice.org/plugins/gitiles/lode/+/ bea0738dbadfe8784e5d3c00f533acf101db4e7e%5E%21> "tb_slave_wrapper: trap signal and kill -9 everything"). This is in line with the waiting in tearDown in unotest/source/python/org/libreoffice/unotest.py, and with the corresponding behavior of C++ and Java test frameworks in unotest. Change-Id: Ieb5c48964428bc05fa8c0f83af9426641d6df693 Reviewed-on: https://gerrit.libreoffice.org/80175 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sberg...@redhat.com> diff --git a/uitest/libreoffice/connection.py b/uitest/libreoffice/connection.py index 5beb1831820c..12917555a2fe 100644 --- a/uitest/libreoffice/connection.py +++ b/uitest/libreoffice/connection.py @@ -130,19 +130,7 @@ class OfficeConnection: else: self.soffice.terminate() - DEFAULT_SLEEP = 0.1 - time_ = 0 - while time_ < 30: - time_ += DEFAULT_SLEEP - ret = self.soffice.poll() - if ret is not None: - break - time.sleep(DEFAULT_SLEEP) - - if ret is None: - self.soffice.terminate() - - # ret = self.soffice.wait() + ret = self.soffice.wait() self.xContext = None self.socket = None self.soffice = None _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits