cypress: mobile: Add more tests for changing shape line properties.
Change-Id: I7eb2132b591f081087dca1999ce81e002ccd5101 Reviewed-on: https://gerrit.libreoffice.org/c/online/+/88972 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
This commit is contained in:
parent
7de5068426
commit
28029dce14
1 changed files with 106 additions and 4 deletions
|
@ -46,11 +46,9 @@ describe('Change shape properties via mobile wizard.', function() {
|
|||
cy.get('#PosSizePropertyPanel')
|
||||
.click();
|
||||
|
||||
cy.get('#selectwidth .spinfield')
|
||||
cy.get('#selectwidth .plus')
|
||||
.should('be.visible')
|
||||
.clear()
|
||||
.type('4.2')
|
||||
.type('{enter}');
|
||||
.click();
|
||||
}
|
||||
|
||||
it('Check default shape geometry.', function() {
|
||||
|
@ -229,4 +227,108 @@ describe('Change shape properties via mobile wizard.', function() {
|
|||
cy.get('.leaflet-pane.leaflet-overlay-pane svg g svg g g g path[fill="none"]')
|
||||
.should('have.attr', 'stroke', 'rgb(152,0,0)');
|
||||
});
|
||||
|
||||
it('Change line style', function() {
|
||||
// TODO: Two issues are found here with core/master
|
||||
// 1) The mobile wizard keeps rerendering after it was already opened which leads
|
||||
// detached item error.
|
||||
// 2) Layout of the line properties panel is completely broken.
|
||||
if (Cypress.env('LO_CORE_VERSION') === 'master')
|
||||
return;
|
||||
|
||||
// Open mobile wizard
|
||||
cy.get('#tb_actionbar_item_mobile_wizard')
|
||||
.click();
|
||||
|
||||
// Change line color
|
||||
cy.get('#LinePropertyPanel')
|
||||
.click();
|
||||
|
||||
cy.get('#linestyle')
|
||||
.click();
|
||||
|
||||
cy.get('.ui-combobox-text')
|
||||
.contains('Fine Dotted')
|
||||
.click();
|
||||
|
||||
triggerNewSVG();
|
||||
|
||||
cy.get('.leaflet-pane.leaflet-overlay-pane svg g svg g g g path[fill="none"]')
|
||||
.should('have.length.greaterThan', 20);
|
||||
});
|
||||
|
||||
it('Change line width', function() {
|
||||
// TODO: Two issues are found here with core/master
|
||||
// 1) The mobile wizard keeps rerendering after it was already opened which leads
|
||||
// detached item error.
|
||||
// 2) Layout of the line properties panel is completely broken.
|
||||
if (Cypress.env('LO_CORE_VERSION') === 'master')
|
||||
return;
|
||||
|
||||
// Open mobile wizard
|
||||
cy.get('#tb_actionbar_item_mobile_wizard')
|
||||
.click();
|
||||
|
||||
// Change line width
|
||||
cy.get('#LinePropertyPanel')
|
||||
.click();
|
||||
|
||||
cy.get('#linewidth .plus')
|
||||
.click();
|
||||
|
||||
triggerNewSVG();
|
||||
|
||||
cy.get('.leaflet-pane.leaflet-overlay-pane svg g svg g g g path[fill="none"]')
|
||||
.should('have.attr', 'stroke-width', '141');
|
||||
|
||||
// Reopen mobile wizard
|
||||
cy.get('#tb_actionbar_item_mobile_wizard')
|
||||
.click();
|
||||
cy.get('#mobile-wizard')
|
||||
.should('not.be.visible');
|
||||
|
||||
cy.get('#tb_actionbar_item_mobile_wizard')
|
||||
.click();
|
||||
cy.get('#mobile-wizard')
|
||||
.should('be.visible');
|
||||
|
||||
// Change line width
|
||||
cy.get('#LinePropertyPanel')
|
||||
.click();
|
||||
|
||||
cy.get('#linewidth .minus')
|
||||
.click();
|
||||
|
||||
triggerNewSVG();
|
||||
|
||||
cy.get('.leaflet-pane.leaflet-overlay-pane svg g svg g g g path[fill="none"]')
|
||||
.should('have.attr', 'stroke-width', '141');
|
||||
});
|
||||
|
||||
it('Change line transparency', function() {
|
||||
// TODO: Two issues are found here with core/master
|
||||
// 1) The mobile wizard keeps rerendering after it was already opened which leads
|
||||
// detached item error.
|
||||
// 2) Layout of the line properties panel is completely broken.
|
||||
if (Cypress.env('LO_CORE_VERSION') === 'master')
|
||||
return;
|
||||
|
||||
// Open mobile wizard
|
||||
cy.get('#tb_actionbar_item_mobile_wizard')
|
||||
.click();
|
||||
|
||||
// Change line color
|
||||
cy.get('#LinePropertyPanel')
|
||||
.click();
|
||||
|
||||
cy.get('#linetransparency .spinfield')
|
||||
.clear()
|
||||
.type('20')
|
||||
.type('{enter}');
|
||||
|
||||
triggerNewSVG();
|
||||
|
||||
cy.get('.leaflet-pane.leaflet-overlay-pane svg g svg g g g defs mask linearGradient')
|
||||
.should('exist');
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue