Cypress sometimes fails with 'DOM element is detached'
failure because of the animation in the mobile wizard.
Disable animation instead of waiting for 100 ms.
I tried to override $.fn.show() function, but it's
actually overriden by JQuery.ui code.
Change-Id: I0e8e937a501a99b1106d7a450088760f67102bc2
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/91569
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
There are cases sometimes, where we can't use cypress'
nice retry feature for waiting to an assumption to
be true. A workaround for this issue is the cypress-wait-until
package, which makes us able to use the retry feature for
any use case.
An example is the position of an element. I don't know
a way to wait on the position to get changed in the cypress
test framework. So we can use cy.waitUntil() here instead.
Please use this new package when it's really necessary,
do not replace the better cypress calls with it.
Change-Id: I8c553456e351664e30043b8ccd5ace51f1c0298d
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/91554
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
It's a known issue that text selection is persistent,
which made these tests unstable. So use a different method
to remove the text selection.
Change-Id: I46b0ba268a39bae9e79ce62686b2d1e0eab1adda
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/91486
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Two issues here:
* Select All does nothing if one column is already selected.
* Three number formatting item is missing from the mobile wizard.
Change-Id: I1f3976ba01c7cf53a58e08d37a5f55f14c3f154f
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/91417
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
cypress test framework has a problem with some
specific hashes (for example: 769e98018) and it
do not pass these values to the test code, which
make all test fail with 404 error.
Change-Id: I385b1621de25fdf90e6169bdff25eaf3c18cf81e
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/91101
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
If we show the mobilw wizard instantly after the mobile
wizard toolbar button is pushed, then mobile wizard will
be an empty bottom panel with an undefined content. It's
better to show the content, only after we get the
sidebar content from core.
For example, if the hamburger menu was displayed in the
bottom panel previously then we will see a white screen
first when we push the mobile wizard toolbar button. This
white screen is the background layout of the mobile wizard.
It looks wierd and also makes testing hard since we have
some wierd dummy HTML structures.
Change-Id: I852bce1ca1460b2210229bec294a249a47523099
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/91062
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
We only need to expose a couple of helpers
to test the keyboard and clipboard, which
are not possible to test via the UI.
This patch reduces the surface area of
exposed code to testing, to avoid misuse.
The only needed helpers should be made
available, and they are read-only functions,
so there is no risk of changing the internal
state from test code.
Change-Id: Id4a1800e3d3b9364754a18fb11f61df612e56490
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90991
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Andras Timar <andras.timar@collabora.com>
To make it work both with release and debug core
build.
Also disable some tests failing with core/cp-6-2.
Change-Id: I5617712e19dc8aaba0c5f9fbdf9c17d9a19fb18b
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90725
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
During parallel build.
Change-Id: I18d78250650e5d16ff9a4ff8588a2e955a934f44
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90721
Tested-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
In some use cases this time was too long and hammerjs
recognized a pan end by 'pointerup' event. We have
500 ms time set for long press in loleaflet code,
so use the exact value here.
Change-Id: Iab47c668ffa591ccfd7d2eeed10f2c3ec5664b89
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90723
Tested-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
There is no assertInTextEditMode() in calc_helper.js.
This reverts commit bc5bf2eb2a.
Change-Id: I97526eb8ea0297a2ea28080f09c85e4284d70932
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90719
Tested-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Which indicates that the application stepped into edit mode.
Change-Id: I196851c618fd3b6c670b26184e6bbca8050f2f5a
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90711
Tested-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Using CTRL+A is simpler, but with using the Hamburger menu we can
make sure that menu item is working. CTRL+A is not an actual
feature on mobile. Also it's good that we use hamburger menu, so
we can check interaction of hamburger menu and other wizards
using the same bottom panel.
Change-Id: I640e515070046ad18b00be69509ed895844962a0
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90710
Tested-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Change-Id: Ieadca0bdb5668d0bdc8ee9356879b652b540ab3c
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90659
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Tested-by: Pedro Pinto da Silva <pedro.silva@collabora.com>
Reviewed-by: Pedro Pinto da Silva <pedro.silva@collabora.com>
Previously we supressed the keyboard after toolbar
actions, but that is problematic because then the
user is unable to delete/replace selected text,
because the keyboard is hidden and there is no way
of showing keyboard without changing the selection.
Now we maintain the keyboard state, which is likely
visible, since a selection shows the keyboard.
This might not be ideal, because the user might
hide the keyboard on the device and we will restore
it after invoking a toolbar action, but at least
it's more usable now. Unfortunately, there is no
API to track the keyboard visibility.
New Cypress tests added to validate the above.
The tests depend on checking the last keyboard
visibility state in Map, because there is no
reliable (or any?) way to know whether the keyboard
is visible or not. There are many cases where we
actually hide the keyboard, while having the input
focus on the textarea element, so that is no indication
that the keyboard is visible. We do this for usability
purposes. For example, during zooming, when selecting
cells and graphics/shapes, etc.
The purpose of the cell is to validate that we restored
the keyboard visibility or we changed it, depending
on which is expected after each operation.
Change-Id: If0f2e96909ff20753043734789397d190cedb502
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90663
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Single- and double-click starts editing
text-boxes in Impress. Single-clicking works
only on text, not in the white-space.
Merges an existing test with a new one to
minimize redundancy where there is overlap.
Improved helpers to minimize duplication
and update a single place when there are changes
to the common operations/checks.
ESLint version set to 6 to support the inline
closure syntax that 5 doesn't support. This is
only used for tests, so perhaps we should have
a different ESLint config for leaflet to avoid
breaking IE11, which is pre-6.
Change-Id: I14ee65b18e310f4ff6b93ce81580b3d6aba0fa03
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90360
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Testing focus is hard in general. Easy to hit race contiditions
when focus behaves inconsistently.
Change-Id: Ib16789d5a9875e8041785ba353b7ab8f7c82a7a7
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90658
Tested-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Now it works both with '-j' and with '-j <number>'.
Change-Id: I41ebace6fd799f103ce557a8cf8419fea786faca
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90496
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
We need to actually wait, until the admin console displays the info
coming from loolwsd. We also need to check only for the test document
that the current test file is using. In parallel build, more jobs
are using the same loolwsd.
Change-Id: Ia85cf711f33c748cdbed8602a532fb590fe26b25
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90474
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
To get a better log in case of error.
Change-Id: Id8f72c78cb8a80e30ba3012147caa8106e1e7ce2
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90470
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>