Commit graph

315 commits

Author SHA1 Message Date
Michael Meeks
65540da9dc test: use process groups as well to allow concurrent make checks.
Change-Id: Ib1a55f53c51835a8f9fb1c17146f30e887103906
2019-05-14 21:29:12 +01:00
Jan Holesovsky
40f840a4ab Fix build.
Change-Id: I2196731cf680ae9d466bf243ddbbb6e10da2455c
2019-05-14 10:11:21 +02:00
merttumer
0dbf9bcf27 Added RenameFile Support for WOPI
This patch concerns rename file operation when the integration
supports it
Signed-off-by: merttumer <mert.tumer@collabora.com>

Change-Id: Ibb4f615b91dda2491bfcd4d4738198d69eca4e6f
Reviewed-on: https://gerrit.libreoffice.org/71587
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
Signed-off-by: merttumer <mert.tumer@collabora.com>
2019-05-13 22:29:40 +03:00
Michael Meeks
501caaa164 test: better zombie handling for more recent kernels.
Change-Id: I2ae0bcc4c42100ee08ee3fcf68cb7022f38aed7b
2019-05-10 17:38:08 +01:00
Michael Meeks
47a0f836dd tests: re-factor PNG save to allow easy re-use elsewhere.
Change-Id: Ic24f67d9a078ae49fa4ac187cc924fe36f482879
2019-05-10 17:37:50 +01:00
Michael Meeks
956f8bf5e8 Unipoll: move event processing into the same thread.
Change-Id: I15aff3b5f18201eca915da94dbaa05148026e244
2019-05-10 14:43:27 +01:00
Michael Meeks
4e1ad1af8d SVG: update for current core.
Reviewed-on: https://gerrit.libreoffice.org/71684
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
(cherry picked from commit f68e68a7b1a6b985f06aff92d95ce178d323e91c)

Conflicts:
	test/data/non_shape_writer_image.svg
	test/data/shapes_writer.svg

Change-Id: Ibb5da2d71ebd68a13b8ccc2a23f891320508f0a5
2019-05-09 15:00:05 +02:00
Miklos Vajna
1d32dc1742 Fix HTTPWSTest::testRenderShapeSelectionImpress() against product core
This test only passed when core.git was built in a way so that '#if
OSL_DEBUG_LEVEL > 0' was true (debug, dbgutil builds). Re-generate this
against a product build, since 2 other tests already have references
like that.

We already have infrastructure for stripping <desc> XML elements from
the actual result.

Change-Id: I9cdd53bf9625266d94313a90946270bfc266bd47
2019-05-09 14:25:21 +02:00
Miklos Vajna
aa5b28ceb0 test: fix HTTPWSTest::testRenderShapeSelectionWriterImage() failure with ...
... debug core.git. Same problem, need to filter out <desc> XML
elements.

Change-Id: I84973b831508e6a073d9c75868307d98a2ada370
2019-05-09 10:40:25 +02:00
Miklos Vajna
0fbabb7a22 test: fix HTTPWSTest::testRenderShapeSelectionWriter() failure with ...
... debug core.git.

SVGActionWriter::ImplWriteActions() in core.git writes additional <desc>
XML elements, guarded with a '#if OSL_DEBUG_LEVEL > 0' block.

Filter these out, so the reference SVG will match both product and debug
builds.

Change-Id: Iba3fb25af206c70d5a4ff5801a934dcfd74704de
2019-05-09 10:30:11 +02:00
Andras Timar
21012c1c74 do not ignore the result of fwrite...
... at least from compiler point of view.
On some systems with old glibc (<= 2.15) the fwrite function has
the warn_unused_result attribute. That makes the build fail.
Starting with glibc 2.16 the attribute was removed [1].

[1]
The bug: https://sourceware.org/bugzilla/show_bug.cgi?id=11959
Release notes to 2.16:
https://sourceware.org/ml/libc-alpha/2012-06/msg00807.html

Change-Id: Ia62ccff2120dce51e311303124aadc60c134a1aa
Reviewed-on: https://gerrit.libreoffice.org/71880
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
2019-05-06 23:11:08 +02:00
Michael Meeks
264450758a test: close testCrashKit race.
LOOLWSD is conservative and leaves forkit to start processes for a
while. If we kill a kit before it has started and registered we can
end up with LOOLWSD holding off to wait for the (now dead) kit, and
the tearDown assertions that we have 1 kit failing.

Change-Id: Id25e48bf55d1757d2223816293500fde6ff9df1b
Reviewed-on: https://gerrit.libreoffice.org/71811
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2019-05-05 00:04:00 +02:00
Michael Meeks
92603013de test: recommend --verbose mode, and interleave output chronologically.
Avoids a number of unpleasant attempts to interleave output.

Change-Id: I84b25e338b576d88f7f5fc47fbfcae34c3d377fd
2019-05-04 22:57:00 +01:00
Michael Meeks
2943d09669 test: encourage the test script to sleep for the debugger too.
Change-Id: I538b2d80f57ecc8a342a38a64864d16b9128a04f
Reviewed-on: https://gerrit.libreoffice.org/71804
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2019-05-04 23:53:38 +02:00
Michael Meeks
abbe1de459 Update unit test data for recent master.
Also add better printout for unit-client case.

Change-Id: Ic3c5573eab55ad5469adefa5bbfbd6c0e05e571e
2019-05-03 14:04:57 +01:00
Michael Meeks
c08b2f2ba4 Improve pid collection and printout for tests.
Change-Id: I820c1acbdbae41dd2c2c6bb7285b84bbb61e79d5
2019-05-03 13:52:15 +01:00
Michael Meeks
5406a25b24 tests: make SVG comparison tests much more helpful.
Dump the SVG we actually get as a .new file for easy upgrade and
comparison on mismatch.

Change-Id: I607a97ff27a9bf480524efc31877e46d74c5ee3d
Reviewed-on: https://gerrit.libreoffice.org/71681
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2019-05-02 17:16:08 +02:00
Michael Meeks
95e1034d27 test: help people run just the one that matters.
Change-Id: I1916e250613f8d50377180e38505045f71f51fd0
Reviewed-on: https://gerrit.libreoffice.org/71642
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2019-05-01 23:14:04 +02:00
Michael Meeks
98fb165c69 Adapt test for new hiddenparts field.
Change-Id: Id2173a38167b97327d0735dfe2a8c88e2dcc4bc7
Reviewed-on: https://gerrit.libreoffice.org/71640
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2019-05-01 22:56:17 +02:00
Eduard Ardeleanu
d87146d3fa fix: saveAs breaks when '%' character is used within the filename
Change-Id: I2df059abd67be88acae8bd44ae2c74be7778a595
Reviewed-on: https://gerrit.libreoffice.org/69424
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-03-19 18:31:15 +01:00
Michael Meeks
6634d3b3e9 TileCache: key almost everything on TileDesc instead of string names.
Saves lots of string construction and storage, simplifies lots of code.

Store the more exotic font-caching bits etc. in a separate store: we
should also pre-render these really and share them.

Change-Id: Icaeff8fd72f52d7215c06a687b1e39cfb7631503
2019-03-05 06:58:50 +01:00
Michael Meeks
0c46b33e72 Don't use the same std::ostringstream from multiple threads.
Avoids tests crashing with obscure memory errors re-allocating the
string buffer; and hopefully cleans up the output too.

Change-Id: I3e38680c15129e84f0c7dd8cada3b505cf08ad34
2019-03-04 22:04:46 +01:00
Tor Lillqvist
8f71365f0f Remove unnecessary leftovers after Michael's removal of the on-disk tile cache
Change-Id: I435679b48f90d2580bb9c5c86a26c9a1d43c5b59
Reviewed-on: https://gerrit.libreoffice.org/67885
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2019-02-15 21:36:16 +01:00
Michael Meeks
66ac62429c TileCache: switch to in-memory, rather than persistent.
Remove significant complexity; if we need it later lets do it more simply
serializing when we start / finish a session.

Turn off caching for mobile - possibly should kill for single-user too.

Change-Id: I5ea56088ddbb61f22fe7920f8c9ac7440cb3296a
2019-02-15 12:10:16 +01:00
Michael Meeks
36e9d5b376 TileCache: re-factor API to work in terms of vectors, not file references.
Change-Id: Ia9d48773121ab965b79ddb16b55b5d3fdcd7fd5c
2019-02-14 21:46:39 +01:00
Jan Holesovsky
ce95c52234 Fix build.
Change-Id: I434a22f14482bf901d08b7c833eaff01e7c9c4f5
2019-02-14 08:44:46 +01:00
Michael Meeks
92cf5707cf Add calc / typing unit test.
Change-Id: Ib62ad6e1a720bdfce41ed5520d7396e83c8f5a91
2019-02-13 18:24:36 +01:00
Michael Meeks
f98a7f0592 Improve unit test / SSL handling & detection.
Change-Id: I6bd3116ac94d3d2c61e2ec543cb17896834ef2df
2019-02-13 18:24:36 +01:00
Jan Holesovsky
f76b36193d android: #if(n)def MOBILEAPP -> #if (!)MOBILEAPP for better reliability.
Change-Id: I5f9c9420b6c83601db1c8fdba4ae5a10b17b2107
2019-02-12 12:20:11 +01:00
Miklos Vajna
d11056deaa test: use the more effective overload accepting a character for find_last_of()
Instead of the one that takes a string literal consisting of a single
character.

Also remove the clang-tidy target, 'run-clang-tidy' does a better job of
doing the same today.

Change-Id: I58f55a0e64af42694d55f9588f25618164275852
2019-01-23 09:06:04 +01:00
Ashod Nakashian
30fb30cff4 wsd: use same method to parse json
DynamicStruct is also more recent and is missing
from older distros and versions of Poco, so avoid
using it just for that.

Change-Id: I465fbbc4350101d382877bd42a1704e4e7827102
2019-01-22 14:52:40 +01:00
Tamás Zolnai
b007656e6a Add a test case of SVG export of Writer image
Change-Id: Ic81754d965a89106f50866a148c7ced0be4a3e9a
2019-01-22 14:52:39 +01:00
Tamás Zolnai
e394999caa Add test case for SVG export of selected shapes in case of Writer
Change-Id: I96e4e4bb098ea37974d6cc684c9b8170ad72869e
2019-01-22 14:52:39 +01:00
Miklos Vajna
05e409fb94 Remove unused 'Timestamp' using decl
Change-Id: If71dd6ef849c530b3c39ab55e0640d597f5a0b2f
2019-01-22 09:19:39 +01:00
Tomaž Vajngerl
7137c953d8 add export, sign and upload as one function for PDF signing
PDF export, signing and upload needs to be done in one operation
as PDF doesn't change the current document. The workflow is just
a bit different to the ODF / OOXML that it needs a change in
behaviour.

Change-Id: I752b293494a2d677fa7f12f2317954cfcf47859b
2019-01-13 23:50:18 +01:00
Andras Timar
9200c0afdf Remove empty Configuration2/ from ODT, it's better for testing signing
Change-Id: I1a10d57ea10c8006b2cdbbe4a674f9177fb35246
2018-12-28 13:10:16 +01:00
Miklos Vajna
1dd2f823e9 UnitFuzz: avoid manual std::move()
std::move() is implemented with release + reset in fact.

Change-Id: If5f0dc8f10066a7ee1ca37f7c5039fcd0affb755
2018-12-18 09:14:43 +01:00
Tamás Zolnai
209e1cd7ee Handle Special character toolbar item state correctly
The toolbar item should have the same names as the UNO command in lower case.

Change-Id: I68264e7d58cca829084965fb5ea9686a85ccd9cd
2018-12-14 17:59:00 +01:00
Miklos Vajna
f38ac3d8ba UnitWOPIDocumentConflict: no c_str() when it'll be converted back to std::string
Change-Id: Ia87598c35f5c8423b22cab0fe8e39fbd1e0818ff
2018-12-14 09:07:22 +01:00
Miklos Vajna
b773f11bdb WopiTestServer: make members private
Change-Id: If042fab5b69faf7c7dff975a95810cb96d8f02b0
2018-12-13 08:49:09 +01:00
Miklos Vajna
d390d646a6 WhiteBoxTests: clean up redundant member initialization
Change-Id: I7b9a4453a94df0a9311bfdb6c0ea3bf8c8e74208
2018-12-12 09:03:15 +01:00
Miklos Vajna
e9e1db61cc HTTPWSTest::testRenderShapeSelection: this test expects an SVG generated by core 6.0
So avoid the test with newer core, which generates a slightly different
SVG.

Change-Id: I9357530735640a40a176140e26ddeb334cd7e89f
2018-12-11 09:10:43 +01:00
Tamás Zolnai
406ae1be86 Update test SVG after export was optimized a bit
Change-Id: I40f402105e603ba793abdff95219319ed92df5ba
2018-12-07 12:39:27 +01:00
Tamás Zolnai
bdab8184a8 Remove unneeded lines from rendershapeselection test
SelectAll does the selection.

Change-Id: I2642b9c1eef1398fa78f39a1a6645e0cf7d266bb
2018-12-07 12:39:27 +01:00
Ashod Nakashian
e5723a22d7 wsd: update bundled headers and improve renderShapeSelection test
Unfortuantely it still fails, but this is not regression. Now
with the new patch in Core the exception is caught and so at least
the binary survives (and the API returns 0).
New unit-test added in Core to help track the issue down and fix.

Also, free the memory allocated by the API.

Change-Id: I5d788a2ee0383de1c323af4cd6b39b8615a35baf
2018-12-07 12:39:27 +01:00
Tamás Zolnai
4df9fd41a3 Update test SVG
Change-Id: I55a3ae676c6eb71e8e34f98f3361f9046e0a4a2f
2018-12-07 12:39:27 +01:00
Tamás Zolnai
b34b1242d6 Remove unneeded include used for debugging only
Change-Id: I82efb9b6d0a0e6ffdca4b9205804446bc871ef84
2018-12-07 12:39:27 +01:00
Tamás Zolnai
31f99bf9f5 Introduce client-server message for requesting the selected shape as SVG
It works for Impress only now.

Change-Id: I130707d8e96e0c633f2531b1cb81ce74dc6ec6e1
2018-12-07 12:39:27 +01:00
Ashod Nakashian
33aff0ce61 wsd: utility to parse integer lists
A quite common logic that is best moved to a utility
and optimized for best performance.

Includes unit-tests.

Change-Id: Id63a388690c17355eb2fac529070c38e9b082fd0
2018-12-07 12:39:27 +01:00
Miklos Vajna
c04fd49d42 TileCacheTests: these writes are never read
They are written again inside the do { ... } while (...) which runs at
least once.

Change-Id: I9ff07d7cb68b73bccf1bd38490fcba615b87a6ba
2018-12-05 09:14:50 +01:00