Skip to content

Commit fa03a2e

Browse files
gokaysatireszkadev
authored andcommitted
Cypress Calc: Make sure triple click selects the cell content.
Signed-off-by: Gökay Şatır <[email protected]> Change-Id: I494fd4343130bf2397fb230f6ead8df4203c23f3
1 parent f2022bf commit fa03a2e

File tree

3 files changed

+24
-0
lines changed

3 files changed

+24
-0
lines changed
21.6 KB
Binary file not shown.

cypress_test/integration_tests/desktop/calc/cell_cursor_spec.js

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -161,6 +161,30 @@ describe(['tagdesktop', 'tagnextcloud', 'tagproxy'], 'Test jumping on large cell
161161
});
162162
});
163163

164+
describe(['tagdesktop', 'tagnextcloud', 'tagproxy'], 'Test triple click content selection.', function() {
165+
166+
beforeEach(function() {
167+
helper.setupAndLoadDocument('calc/cell-content-selection.ods');
168+
});
169+
170+
it('Triple click should select the cell content.', function() {
171+
helper.typeIntoInputField(helper.addressInputSelector, 'A1');
172+
173+
// Triple click on second first in second row
174+
cy.cGet('#document-container')
175+
.then(function(items) {
176+
expect(items).to.have.lengthOf(1);
177+
var XPos = items[0].getBoundingClientRect().left + 60;
178+
var YPos = items[0].getBoundingClientRect().top + 30;
179+
cy.cGet('body').click(XPos, YPos).click(XPos, YPos).click(XPos, YPos); // Triple click.
180+
});
181+
182+
cy.wait(2000);
183+
cy.cGet('#document-canvas').compareSnapshot('triple-click', 0.02);
184+
185+
});
186+
});
187+
164188
describe(['tagdesktop', 'tagnextcloud', 'tagproxy'], 'Test decimal separator of cells with different languages.', function() {
165189
beforeEach(function() {
166190
helper.setupAndLoadDocument('calc/decimal_separator.ods');
96.7 KB
Loading

0 commit comments

Comments
 (0)