Browse Source

test: delete table - add class to avoid ambiguity

nc-refactor/ds
Pranav C 1 month ago
parent
commit
46da690cdd
  1. 2
      packages/nc-gui/components/dashboard/TreeView/TableNode.vue
  2. 2
      tests/playwright/pages/Dashboard/TreeView.ts

2
packages/nc-gui/components/dashboard/TreeView/TableNode.vue

@ -358,7 +358,7 @@ const deleteTable = () => {
<NcMenuItem
v-if="isUIAllowed('tableDelete', { roles: baseRole })"
:data-testid="`sidebar-table-delete-${table.title}`"
class="!text-red-500 !hover:bg-red-50"
class="!text-red-500 !hover:bg-red-50 nc-table-delete"
@click="deleteTable"
>
<div v-e="['c:table:delete']" class="flex gap-2 items-center">

2
tests/playwright/pages/Dashboard/TreeView.ts

@ -182,7 +182,7 @@ export class TreeViewPage extends BasePage {
await this.waitForTableOptions({ title });
await this.get().locator(`.nc-base-tree-tbl-${tableTitle}`).locator('.nc-tbl-context-menu').click();
await this.rootPage.locator('.ant-dropdown').locator('.nc-menu-item:has-text("Delete")').click();
await this.rootPage.locator('.ant-dropdown').locator('.nc-menu-item.nc-table-delete:has-text("Delete")').click();
await this.waitForResponse({
uiAction: async () => {

Loading…
Cancel
Save