You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2020/10/14 22:06:22 UTC

[GitHub] [incubator-superset] adam-stasiak commented on a change in pull request #11049: chore: Dashboard cypress refactor

adam-stasiak commented on a change in pull request #11049:
URL: https://github.com/apache/incubator-superset/pull/11049#discussion_r505006582



##########
File path: superset-frontend/cypress-base/cypress/integration/dashboard/edit_mode.test.js
##########
@@ -23,47 +23,55 @@ describe('Dashboard edit mode', () => {
     cy.server();
     cy.login();
     cy.visit(WORLD_HEALTH_DASHBOARD);
-    cy.get('.dashboard-header [data-test=edit-alt]').click();
+    cy.get('[data-test="dashboard-header"]').find('[data-test=pencil]').click();
   });
 
   it('remove, and add chart flow', () => {
     // wait for box plot to appear
-    cy.get('.grid-container .box_plot');
+    cy.get('[data-test="grid-container"]').find('.box_plot');
 
-    cy.get('.fa.fa-trash')
+    cy.get('[data-test="icon-button"]')
       .last()
       .then($el => {
         cy.wrap($el).invoke('show').click();
         // box plot should be gone
-        cy.get('.grid-container .box_plot').should('not.exist');
+        cy.get('[data-test="grid-container"]')
+          .find('.box_plot')
+          .should('not.exist');
       });
 
-    cy.get('.tabs-components .nav-tabs li a').contains('Charts').click();
+    cy.get('[data-test="tabs-component"]').children().siblings().last().click();
 
     // wait for tab-switching animation to complete
     cy.wait(1000);
 
     // find box plot is available from list
-    cy.get('.tabs-components')
-      .find('.chart-card-container')
+    cy.get('[data-test="dragdroppable-object"]')
+      .find('[data-test="card-title"]')

Review comment:
       it is for better reflecting components structure. In object dragdroppable-object I expect to find card-title. Just a pattern to better see changes in case of some components breakup




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org