[Libreoffice-commits] online.git: cypress_test/integration_tests
Tamás Zolnai (via logerrit)
logerrit at kemper.freedesktop.org
Mon Feb 24 23:38:00 UTC 2020
cypress_test/integration_tests/mobile/writer/shape_properties_spec.js | 23 +++++++++-
1 file changed, 21 insertions(+), 2 deletions(-)
New commits:
commit 907a23bf0c8cca4e2b0bce9936778b65c6c653d5
Author: Tamás Zolnai <tamas.zolnai at collabora.com>
AuthorDate: Mon Feb 24 23:24:15 2020 +0100
Commit: Tamás Zolnai <tamas.zolnai at collabora.com>
CommitDate: Tue Feb 25 00:37:42 2020 +0100
cypress: mobile: improve shape geometry tests.
Change-Id: I46b2384da6c406c66e3f5d19838df1e87804b2a9
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89390
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice at gmail.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai at collabora.com>
diff --git a/cypress_test/integration_tests/mobile/writer/shape_properties_spec.js b/cypress_test/integration_tests/mobile/writer/shape_properties_spec.js
index 61613f0c0..edca39a77 100644
--- a/cypress_test/integration_tests/mobile/writer/shape_properties_spec.js
+++ b/cypress_test/integration_tests/mobile/writer/shape_properties_spec.js
@@ -3,6 +3,8 @@
var helper = require('../../common/helper');
describe('Change shape properties via mobile wizard.', function() {
+ var defaultGeometry = 'M 1965,4810 L 7957,10802 1965,10802 1965,4810 1965,4810 Z';
+
beforeEach(function() {
helper.beforeAllMobile('shape_properties.odt', 'writer');
@@ -79,7 +81,7 @@ describe('Change shape properties via mobile wizard.', function() {
it('Check default shape geometry.', function() {
// Geometry
cy.get('.leaflet-pane.leaflet-overlay-pane svg g svg g g g path')
- .should('have.attr', 'd', 'M 1965,4810 L 7957,10802 1965,10802 1965,4810 1965,4810 Z');
+ .should('have.attr', 'd', defaultGeometry);
// Fill color
cy.get('.leaflet-pane.leaflet-overlay-pane svg g svg g g g path')
.should('have.attr', 'fill', 'rgb(114,159,207)');
@@ -97,6 +99,9 @@ describe('Change shape properties via mobile wizard.', function() {
.type('4.2')
.type('{enter}');
+ cy.get('.leaflet-pane.leaflet-overlay-pane svg g svg g g g path')
+ .should('have.attr', 'd', defaultGeometry);
+
cy.get('.leaflet-pane.leaflet-overlay-pane svg g svg g g g path')
.should('have.attr', 'd', 'M 1965,4810 L 12635,10802 1965,10802 1965,4810 1965,4810 Z');
});
@@ -113,6 +118,9 @@ describe('Change shape properties via mobile wizard.', function() {
.type('5.2')
.type('{enter}');
+ cy.get('.leaflet-pane.leaflet-overlay-pane svg g svg g g g path')
+ .should('not.have.attr', 'd', defaultGeometry);
+
cy.get('.leaflet-pane.leaflet-overlay-pane svg g svg g g g path')
.should('have.attr', 'd', 'M 1965,4810 L 7957,18020 1965,18020 1965,4810 1965,4810 Z');
});
@@ -137,6 +145,9 @@ describe('Change shape properties via mobile wizard.', function() {
.type('5.2')
.type('{enter}');
+ cy.get('.leaflet-pane.leaflet-overlay-pane svg g svg g g g path')
+ .should('not.have.attr', 'd', defaultGeometry);
+
cy.get('.leaflet-pane.leaflet-overlay-pane svg g svg g g g path')
.should('have.attr', 'd', 'M 1965,4810 L 15175,18020 1965,18020 1965,4810 1965,4810 Z');
});
@@ -147,6 +158,9 @@ describe('Change shape properties via mobile wizard.', function() {
cy.get('#FlipVertical')
.click();
+ cy.get('.leaflet-pane.leaflet-overlay-pane svg g svg g g g path')
+ .should('not.have.attr', 'd', defaultGeometry);
+
cy.get('.leaflet-pane.leaflet-overlay-pane svg g svg g g g path')
.should('have.attr', 'd', 'M 1965,10800 L 7957,4808 1965,4808 1965,10800 1965,10800 Z');
});
@@ -157,8 +171,13 @@ describe('Change shape properties via mobile wizard.', function() {
cy.get('#FlipHorizontal')
.click();
+ triggerNewSVG();
+
+ cy.get('.leaflet-pane.leaflet-overlay-pane svg g svg g g g path')
+ .should('not.have.attr', 'd', defaultGeometry);
+
cy.get('.leaflet-pane.leaflet-overlay-pane svg g svg g g g path')
- .should('have.attr', 'd', 'M 1965,4810 L 7957,10802 1965,10802 1965,4810 1965,4810 Z');
+ .should('have.attr', 'd', 'M 8010,4810 L 1963,10802 8010,10802 8010,4810 8010,4810 Z');
});
it('Trigger moving backward / forward', function() {
More information about the Libreoffice-commits
mailing list