cypress_test/integration_tests/mobile/calc/focus_spec.js | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-)
New commits: commit a86ddbb3abf24e3407dfe444e07f53c6bc5c9c72 Author: Tamás Zolnai <tamas.zol...@collabora.com> AuthorDate: Fri May 1 12:32:12 2020 +0200 Commit: Tamás Zolnai <tamas.zol...@collabora.com> CommitDate: Fri May 1 12:56:25 2020 +0200 cypress: mobile: fix-up this focus related test. It's not an actual regression, but using clickFormulaBar() method to move the cursor to a specific position is not stable it seems. Change-Id: I9abd470fd1f0f753181f3550df3b41384fa166dc Reviewed-on: https://gerrit.libreoffice.org/c/online/+/93258 Tested-by: Tamás Zolnai <tamas.zol...@collabora.com> Reviewed-by: Tamás Zolnai <tamas.zol...@collabora.com> diff --git a/cypress_test/integration_tests/mobile/calc/focus_spec.js b/cypress_test/integration_tests/mobile/calc/focus_spec.js index 6a5ed60e9..8ed94512c 100644 --- a/cypress_test/integration_tests/mobile/calc/focus_spec.js +++ b/cypress_test/integration_tests/mobile/calc/focus_spec.js @@ -76,8 +76,7 @@ describe('Calc focus tests', function() { .should('be.eq', 'clipboard'); }); - // Regression here: 'BAZINGA' text is typed at an incorrect position. - it.skip('Formula-bar focus', function() { + it('Formula-bar focus', function() { // Click on edit button mobileHelper.enableEditingMobile(); @@ -141,12 +140,16 @@ describe('Calc focus tests', function() { calc.clickFormulaBar(); cy.get('body').trigger('mouseover'); helper.assertCursorAndFocus(); + + // Move cursor before text2 + cy.get('textarea.clipboard').type('{end}'); + for (var i = 0; i < text2.length; i++) + cy.get('textarea.clipboard').type('{leftarrow}'); + var text3 = ', BAZINGA'; helper.typeText('textarea.clipboard', text3); // Validate. cy.get('textarea.clipboard').type('{ctrl}a'); - //NOTE: If this fails, it's probably because we clicked - // at a different point in the text. helper.expectTextForClipboard(text1 + text3 + text2); // End editing. cy.get('textarea.clipboard').type('{enter}'); _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits