You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@superset.apache.org by ru...@apache.org on 2025/12/15 19:42:59 UTC
(superset) branch fix/flaky-chart-list-edit-test created (now 67006088ae)
This is an automated email from the ASF dual-hosted git repository.
rusackas pushed a change to branch fix/flaky-chart-list-edit-test
in repository https://gitbox.apache.org/repos/asf/superset.git
at 67006088ae fix(tests): resolve flaky "should edit correctly" test in chart list
This branch includes the following new commits:
new 67006088ae fix(tests): resolve flaky "should edit correctly" test in chart list
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
(superset) 01/01: fix(tests): resolve flaky "should edit correctly" test in chart list
Posted by ru...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
rusackas pushed a commit to branch fix/flaky-chart-list-edit-test
in repository https://gitbox.apache.org/repos/asf/superset.git
commit 67006088ae1a3957cbd9c7f18fa2cff0f5530d2c
Author: Evan Rusackas <ev...@rusackas.com>
AuthorDate: Mon Dec 15 11:40:31 2025 -0800
fix(tests): resolve flaky "should edit correctly" test in chart list
The test was failing intermittently with "element detached from DOM" error
because after switching from card to list view with setGridMode('list'),
React re-renders the entire view. The test was immediately trying to click
the edit button before the DOM stabilized.
Changes:
- Add wait for loading indicator to disappear after mode change
- Add visibility check for table rows before interacting
- Scope the edit button selector to a specific table row instead of
querying all edit buttons globally, making it more resilient to
DOM changes during re-renders
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <no...@anthropic.com>
---
superset-frontend/cypress-base/cypress/e2e/chart_list/list.test.ts | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/superset-frontend/cypress-base/cypress/e2e/chart_list/list.test.ts b/superset-frontend/cypress-base/cypress/e2e/chart_list/list.test.ts
index 07717f609f..55d1bb2639 100644
--- a/superset-frontend/cypress-base/cypress/e2e/chart_list/list.test.ts
+++ b/superset-frontend/cypress-base/cypress/e2e/chart_list/list.test.ts
@@ -206,7 +206,11 @@ describe('Charts list', () => {
// edits in list-view
setGridMode('list');
- cy.getBySel('edit-alt').eq(1).click();
+ // Wait for list view to fully render after mode change
+ cy.get('.loading').should('not.exist');
+ cy.getBySel('table-row').should('be.visible');
+ // Use a more specific selector scoped to a table row to avoid detached element issues
+ cy.getBySel('table-row').eq(1).find('[data-test="edit-alt"]').click();
cy.getBySel('properties-modal-name-input').clear();
cy.getBySel('properties-modal-name-input').type('1 - Sample chart');
cy.get('button:contains("Save")').click();