Skip to content

Commit

Permalink
Merge pull request #11151 from umbraco/v9/bugfix/fixed_tabs_test_on_e…
Browse files Browse the repository at this point in the history
…very_resolution

v9: fixed tabs test on every resolution
  • Loading branch information
bergmania authored Sep 21, 2021
2 parents ee132af + 4a1dffc commit 1b0911f
Showing 1 changed file with 18 additions and 3 deletions.
21 changes: 18 additions & 3 deletions src/Umbraco.Tests.AcceptanceTest/cypress/integration/Tabs/tabs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,12 @@ context('Tabs', () => {
cy.saveDocumentType(tabsDocType);
OpenDocTypeFolder();
cy.get('[alias="reorder"]').click();
cy.get('.umb-group-builder__tabs-overflow--right > .caret').click().click();
cy.get('body')
.then(($body) => {
while($body.find('.umb-group-builder__tabs-overflow--right > .caret').hasClass('active')){
cy.click();
}
});
cy.get('.umb-group-builder__tab').last().click();
cy.get('.umb-group-builder__group-title-icon').last().trigger('mousedown', { which: 1 })
cy.get('.umb-group-builder__tab').eq(1).trigger('mousemove', {which: 1, force: true});
Expand Down Expand Up @@ -426,7 +431,12 @@ context('Tabs', () => {
OpenDocTypeFolder();
cy.get('[alias="reorder"]').click();
//Scroll right so we can see tab 2
cy.get('.umb-group-builder__tabs-overflow--right > .caret').click().click();
cy.get('body')
.then(($body) => {
while($body.find('.umb-group-builder__tabs-overflow--right > .caret').hasClass('active')){
cy.click();
}
});
cy.get('.umb-group-builder__tab-title-icon').eq(1).trigger('mousedown', { which: 1 })
cy.get('.umb-group-builder__tab').eq(1).trigger('mousemove', {which: 1, force: true});
cy.get('.umb-group-builder__tab').eq(1).should('have.class', 'is-active').trigger('mouseup', {force:true});
Expand Down Expand Up @@ -473,7 +483,12 @@ context('Tabs', () => {
OpenDocTypeFolder();
cy.get('[alias="reorder"]').click();
//Scroll so we are sure we see tab 2
cy.get('.umb-group-builder__tabs-overflow--right > .caret').click().click();
cy.get('body')
.then(($body) => {
while($body.find('.umb-group-builder__tabs-overflow--right > .caret').hasClass('active')){
cy.click();
}
});
//Navigate to tab 2
cy.get('.umb-group-builder__tab').last().click();
cy.get('.umb-group-builder__property-meta > .flex > .icon').eq(1).trigger('mousedown', {which: 1})
Expand Down

0 comments on commit 1b0911f

Please sign in to comment.