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>
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>
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>
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>
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>
Pushing ESC has an unexpected side-effect
on some tests.
Change-Id: I147fcc3aaac21e56450eececf60e8cb99b49655f
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90467
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
It seems sometimes writeFileSync() method does not
actually overwrites the document and some tests loads
a test document modified by an other test.
Hopefully removal of the file will solve this issue.
Change-Id: I2cecfd367acce185eeebbdc4269a73a9d1d2dd5a
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90339
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Use en-US locale. In the tests of date / time fields
the date format contains the locale, which was set to en-US
originally.
Change-Id: Ida56dd8a3e64b0c81d70d010f3aabf40da7d73a0
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/88620
Tested-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
My browser is Spanish by default
Change-Id: I2f3a2aaf7a6b0856c778dc9b943e23f8c168a394
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/88568
Tested-by: Henry Castro <hcastro@collabora.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
To achive a better test covarage.
Now, the simple click() method is recognized
as 'tap' by hummerjs. For long press we need
to use low level events.
I expect that we can emulate other mobile events too
on a similar way.
Change-Id: I5f43afafe087133e707eed6ff8a43765324d5e24
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/88161
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Tested-by: Tamás Zolnai <tamas.zolnai@collabora.com>
And disable some failing tests for core/master.
No idea why these items are missing from paragraph
panel with core/master. Seems a regression from cp-6-2
to master.
Change-Id: Ia91f38cbcf74d0b45730c8643559c298376ae153