Some tests were relying the cursor position for checking the document
dimensions. Those code lines are removed from the tests.
Document size is not able to checked from html elements. Instead, a unit
test may be prepared for that task.
Signed-off-by: Gökay Şatır <gokay.satir@collabora.com>
Change-Id: Idd4fd52656b2969bf0bfa9534a807a7a8bd3f987
All ts files were being compiled upon a change on one of them. Bug
solved.
Signed-off-by: Gökay Şatır <gokay.satir@collabora.com>
Change-Id: I3137d07e7ddf43076bf8b55fbacba1caef6f19cd
The assertion will include much more info than
simply flagging for failure, which helps in
troubleshooting failures.
Change-Id: I6bd649e5334a90e9feaf0d72347790088f70c1b3
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
Normally writeOutgoingData flushes all the available
write buffer to the socket. However, when an error
occures during the write, the flushing loop is
broken and the error is expected to be handled
in the poll loop (or, at any rate, the poll loop
will sooner or later retry).
This doesn't work when the socket is being shut
down. Details and stack-trace is added in the
code to document this scenario.
The proper fix to flushing before shutting
down is to do it asynchronously (i.e. flag for
shutdown, let poll flush the buffers, and then
close the socket), but currently this isn't
easily possible (again, details in the added
comment). For now, we do a second attempt to
write, before we give up and warn of lost data.
Worth noting that this was caught thanks to the
simulated socket error logic. Every so often the
Close Frame of the WebSocket was getting lost.
This frame is asserted in the 'crash test' and
the explanation is that it happened when the
simulated socket error happened to hit during
the writing of the Close Frame (as one statistic
this happened ~15% of the time, when running the
crash test in a loop). With the retrying in this
patch I was able to run the crash test successfully
a few 100 times without failures.
Finally, we unify the flushing with the mobile-app case
to minimize the differences as much as possible and
improved the logging a bit.
Change-Id: I0c0559d6095cd2af8250a7e65a972ba672ecd4b1
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
SSL signals whether it needs more data to read or write
so that we perform the appropriate polling and call
the respective API. Since during error simulation
we skip calling the SSL API altogether, we shouldn't
change the last desired operation it communicated to us.
This becomes clear when we consider that we always read,
unconditionally, in StreamSocket::handlePoll (but write
only when poll signals POLLOUT event). This means that
if we decide to simulate a socket error during such
uncoditional read, and SSL wants to write, we would
reset its last wantsTo flag from write to read!
Logically, since we aren't even invoking any SSL API
during a simulated error, we shouldn't change the
SSL state one way or the other.
Change-Id: Ie4ddbc959f8424ea4ac3bc52f30edbc7399b2c7a
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
The API is the same for both SSL and non-SSL sockets
(they are virtual functions), and the API relies on
errno to detect errors and decide to retry, log, or
break. As such, we must set the same EAGAIN when
simulating socket errors for both SSL and non-SSL
cases, so that the behavior would also be the same.
Change-Id: Ib1695cc94d93f5ecc53d7b22872f459ac8b11bbd
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
This will avoid code duplications.
Middle handle and flat line handles will use the same function
Change-Id: I6fc3509147e3908a39692488305f89c6f8527a1f
Signed-off-by: mert <mert.tumer@collabora.com>
php-proxy slows down things and make it visible, that
cellA1Bounds and cellC3Bounds can be initialized to the same
value. So let's wait fo the cell cursor to be updated before
we set the cellC3Bounds value. Changed the toString() function
to exactly match with the json in the overlay items' text attribute.
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Change-Id: Idde0f516ff568cb14b5d53224fd75ebc6167abe9
This converts Poco to http::Request in sync mode,
thereby not changing functionality. In a follow-up,
this will be converted to async.
Change-Id: Ifbecd44ff599394799c1131470d77f803ed8cc45
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
The implicit transformations done in tile drawing(from offscreen canvas)
must match the canvas transformation done for drawing the overlays.
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: If434eb87be99754a2def290b19631a1970e83488
at the frame zoom level on the main canvas after tilesection is drawn
using off-screen canvas.
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: I45adafae4dc4eaaca27fb9b2d858186b04fb898e