Commit graph

13 commits

Author SHA1 Message Date
Ashod Nakashian
82560d9657 wsd: test assertion macros
Because the new-style tests are intrustive,
the exception that CppUnit throws on assertion
failures is caught and processed with the
application logic, which is far from ideal,
because it's very difficult to find the
cause of failure.

What we'd like is a way to control what happens
when an test assertion fails, such that we can
properly log/print the failure, and even break
in the debugger.

The new macros allow us to control the behavior
at compile-time and have added flexibility.
For now, they log an assertion failure before
invoking the CPPUNIT macro, and support a
compile-time directive to assert, which is
useful for breaking in the debugger.

Change-Id: If464ba246e3ec747f31496a4215cb73ef735dfaf
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/87625
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2020-03-14 15:45:00 +01:00
Tamás Zolnai
19a7f1d288 test: better fix for UnitWOPISaveAs test
Don't check the full URL, but just test some parts of it.

Change-Id: I5367bf4f41dc26f311e03de7ce06349f744d0b85
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90428
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-03-12 17:47:35 +01:00
Ashod Nakashian
d8a9e11ad9 wsd: fix UnitWOPISaveAs test
Change-Id: I63da82da727e2902fdb35ff31b29df8c77976793
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90355
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
2020-03-12 13:19:38 +01: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
Miklos Vajna
b773f11bdb WopiTestServer: make members private
Change-Id: If042fab5b69faf7c7dff975a95810cb96d8f02b0
2018-12-13 08:49:09 +01:00
Ashod Nakashian
0bf78a3ce7 wsd: fix saveas test
It didn't expect the trailing xfilename which
is used for anonymization.

Change-Id: I169253c567583f43ce870bbf5dfcebee9c94cd1d
2018-10-17 19:29:08 -04:00
Pranav Kant
f63858433b loplugin:includeform
Change-Id: Ib62a7aa61062f00698aa3e8a144438de5c57e53d
2017-12-20 21:21:05 +05:30
Jan Holesovsky
b20faa8bdc Save As: Advertise the correct size when uploading the new file.
Change-Id: I9b20c4bdb7ddc848437edceae1a77ddb49d55133
Reviewed-on: https://gerrit.libreoffice.org/44357
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
2017-11-10 11:08:53 +01:00
Jan Holesovsky
d3bf2638ea SaveAs: Fix unit test when used without ssl.
Change-Id: Ic48908c9e7449fc13458d9211fa743310834bd6b
2017-10-26 13:21:18 +03:00
Jan Holesovsky
343c5bc690 tdf#99744 SaveAs: Extend test to check that the Save As result was sent.
Change-Id: I3788b87d2599c01000af97f496ee2b840c0cae3e
2017-10-26 11:11:38 +02:00
Jan Holesovsky
6745464c70 tdf#99744 SaveAs: Report back to loleaflet that the saveas succeeded.
Change-Id: I670c8b4503c1a4c0a88001a1343f6dec2974e044
2017-10-26 11:11:38 +02:00
Jan Holesovsky
6fe4484395 tdf#99744 SaveAs: Use X-WOPI-SuggestedTarget instead of X-WOPI-RelativeTarget.
And the correct encoding - UTF-7 (huh).

Change-Id: I6634fedb598c620128cc25a3e8fdc46e4096a756
2017-10-26 11:11:38 +02:00
Jan Holesovsky
7ff432a370 tdf#99744 SaveAs: Reimplementation of the PutRelativeFile going through Kit.
This is necessary so that changing of the file type works.

Includes a unit test.

Change-Id: Id01d44e555b6bac1002ff950de461fd330602f63
2017-10-26 11:11:38 +02:00