Skip to content
Open
Show file tree
Hide file tree
Changes from 14 commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
7cf6d00
Replaced old entity delete modal with untitles delete modal
anuj-kumary Jul 6, 2026
17c9c79
nit
anuj-kumary Jul 6, 2026
20c6404
fix(test): mock DeleteEntityModal in UserListPageV1 unit test
anuj-kumary Jul 6, 2026
b891809
chore: merge main into issue-29730-oss
anuj-kumary Jul 6, 2026
a775a54
nit
anuj-kumary Jul 6, 2026
d5f38b8
fix the spacing for delete modal
anuj-kumary Jul 6, 2026
40dd0b9
fix(tests): replace stale ant-modal selector with delete-modal testid…
anuj-kumary Jul 6, 2026
7649465
fix(ui): wrap async delete in try/finally to prevent modal stuck on e…
anuj-kumary Jul 6, 2026
50d6f40
Merge branch 'main' into issue-29730-oss
anuj-kumary Jul 6, 2026
9450934
fix(playwright): update stale ant-modal selectors after DeleteEntityM…
anuj-kumary Jul 6, 2026
4c6f400
Merge branch 'main' into issue-29730-oss
anuj-kumary Jul 6, 2026
699b7a9
fix(playwright): replace old hard/soft-delete-option testids in utili…
anuj-kumary Jul 6, 2026
2b3a04b
fix(playwright): migrate TagPage, TagsPage, DataProductsDetailsPage t…
anuj-kumary Jul 7, 2026
9d50f25
Merge branch 'main' into issue-29730-oss
anuj-kumary Jul 7, 2026
38ca7f7
refactor(ui): use DeleteModal for single-option (hard-delete-only) de…
anuj-kumary Jul 7, 2026
fb18ffe
fix(playwright): update delete modal assertions for DeleteModal migra…
anuj-kumary Jul 7, 2026
0f4df1c
Merge branch 'main' into issue-29730-oss
anuj-kumary Jul 7, 2026
41ddfd9
update failing test
anuj-kumary Jul 7, 2026
6d0ed31
fix unit test
anuj-kumary Jul 7, 2026
297c386
fix lint checks
anuj-kumary Jul 7, 2026
e8e57b6
fix playwright test for glossary
anuj-kumary Jul 7, 2026
639d10d
Merge branch 'main' into issue-29730-oss
anuj-kumary Jul 7, 2026
5da0545
Add missing translation key
anuj-kumary Jul 7, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -130,11 +130,10 @@ test.describe(
await page.click('[data-testid="manage-button"]');
await page.click('[data-testid="delete-button"]');

await page.locator('[role="dialog"].ant-modal').waitFor();
await page.getByTestId('delete-modal').waitFor();

await expect(page.locator('[role="dialog"].ant-modal')).toBeVisible();
await expect(page.getByTestId('delete-modal')).toBeVisible();

await page.fill('[data-testid="confirmation-text-input"]', 'DELETE');
const deleteResponse = page.waitForResponse(
`/api/v1/${EntityTypeEndpoint.Dashboard}/async/*?hardDelete=false&recursive=true`
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ import {
toastNotification,
uuid,
} from '../../../utils/common';
import { fillDeleteConfirmationIfPresent } from '../../../utils/entity';
import { findSystemTestDefinition } from '../../../utils/testCases';

const TEST_DEFINITION_NAME = `AaroCustomTestDefinition${uuid()}`;
Expand Down Expand Up @@ -269,8 +270,6 @@ test.describe(
page.getByText(`Delete ${UPDATE_TEST_DEFINITION_DISPLAY_NAME}`)
).toBeVisible();

await page.getByTestId('confirmation-text-input').fill('DELETE');

// Wait for API call
const deleteTestDefinitionResponse = page.waitForResponse(
(response) =>
Expand All @@ -279,6 +278,7 @@ test.describe(
);

// Click confirm delete
await fillDeleteConfirmationIfPresent(page);
await page.getByTestId('confirm-button').click();

const response = await deleteTestDefinitionResponse;
Expand Down Expand Up @@ -743,14 +743,13 @@ test.describe(
page.getByText(`Delete ${createdTestDisplayName}`)
).toBeVisible();

await page.getByTestId('confirmation-text-input').fill('DELETE');

const deleteResponse = page.waitForResponse(
(response) =>
response.url().includes('/api/v1/dataQuality/testDefinitions') &&
response.request().method() === 'DELETE'
);

await fillDeleteConfirmationIfPresent(page);
await page.getByTestId('confirm-button').click();

const response = await deleteResponse;
Expand Down Expand Up @@ -1053,14 +1052,13 @@ test.describe(

await expect(page.locator('.ant-modal')).toBeVisible();

await page.getByTestId('confirmation-text-input').fill('DELETE');

const deleteResponse = page.waitForResponse(
(response) =>
response.url().includes('/api/v1/dataQuality/testDefinitions') &&
response.request().method() === 'DELETE'
);

await fillDeleteConfirmationIfPresent(page);
await page.getByTestId('confirm-button').click();

const response = await deleteResponse;
Expand Down Expand Up @@ -1215,7 +1213,6 @@ test.describe(
.click();

await expect(page.locator('.ant-modal')).toBeVisible();
await page.getByTestId('confirmation-text-input').fill('DELETE');

// Set up both DELETE and the subsequent GET response waits BEFORE clicking
const deleteResponse = page.waitForResponse(
Expand All @@ -1230,6 +1227,7 @@ test.describe(
response.request().method() === 'GET'
);

await fillDeleteConfirmationIfPresent(page);
await page.getByTestId('confirm-button').click();

const deleteResult = await deleteResponse;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ import { expect, test } from '@playwright/test';
import { PLAYWRIGHT_INGESTION_TAG_OBJ } from '../../constant/config';
import { TableClass } from '../../support/entity/TableClass';
import { getApiContext, redirectToHomePage, uuid } from '../../utils/common';
import { fillDeleteConfirmationIfPresent } from '../../utils/entity';
import { getFailedRowsData, visitDataQualityTab } from '../../utils/testCases';

// use the admin user to login
Expand Down Expand Up @@ -115,10 +116,10 @@ test(
await page.click('[data-testid="sample-data-manage-button"]');
await page.click('[data-testid="delete-button"]');
await page.locator('.ant-modal-body').waitFor({ state: 'visible' });
await page.fill('[data-testid="confirmation-text-input"]', 'DELETE');
const deleteSampleData = page.waitForResponse(
'/api/v1/dataQuality/testCases/*/failedRowsSample'
);
await fillDeleteConfirmationIfPresent(page);
await page.click('[data-testid="confirm-button"]');
await deleteSampleData;
await page.locator('[data-testid="sample-data-manage-button"]').waitFor({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -408,18 +408,8 @@ test.describe('Glossary CRUD Operations', () => {
state: 'visible',
});

const confirmInput = page.locator(
'[data-testid="confirmation-text-input"]'
);

if (
await confirmInput.isVisible({ timeout: 2000 }).catch(() => false)
) {
await confirmInput.fill('DELETE');

const confirmBtn = page.getByTestId('confirm-button');
await confirmBtn.click();
}
const confirmBtn = page.getByTestId('confirm-button');
await confirmBtn.click();
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ import { TableClass } from '../../../support/entity/TableClass';
import { Glossary } from '../../../support/glossary/Glossary';
import { GlossaryTerm } from '../../../support/glossary/GlossaryTerm';
import { getApiContext, redirectToHomePage } from '../../../utils/common';
import { fillDeleteConfirmationIfPresent } from '../../../utils/entity';
import {
dragAndDropTerm,
performExpandAll,
Expand Down Expand Up @@ -95,9 +96,9 @@ test.describe('Glossary Miscellaneous Operations', () => {
await expect(page.locator('[role="dialog"]')).toBeVisible();

// Confirm deletion
await page.getByTestId('confirmation-text-input').fill('DELETE');

const deleteRes = page.waitForResponse('/api/v1/glossaries/async/*');
await fillDeleteConfirmationIfPresent(page);
await page.getByTestId('confirm-button').click();
await deleteRes;

Expand Down Expand Up @@ -245,9 +246,9 @@ test.describe('Glossary Miscellaneous Operations', () => {
await expect(page.locator('[role="dialog"]')).toBeVisible();

// Confirm deletion
await page.getByTestId('confirmation-text-input').fill('DELETE');

const deleteRes = page.waitForResponse('/api/v1/glossaryTerms/async/*');
await fillDeleteConfirmationIfPresent(page);
await page.getByTestId('confirm-button').click();
await deleteRes;

Expand Down Expand Up @@ -386,9 +387,9 @@ test.describe('Glossary Miscellaneous Operations', () => {
await expect(page.locator('[role="dialog"]')).toBeVisible();

// Confirm deletion
await page.getByTestId('confirmation-text-input').fill('DELETE');

const deleteRes = page.waitForResponse('/api/v1/glossaryTerms/async/*');
await fillDeleteConfirmationIfPresent(page);
await page.getByTestId('confirm-button').click();
await deleteRes;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
getApiContext,
redirectToHomePage,
} from '../../../utils/common';
import { fillDeleteConfirmationIfPresent } from '../../../utils/entity';
import {
openAddGlossaryTermModal,
performExpandAll,
Expand All @@ -38,19 +39,19 @@
reviewer2Page: Page;
}>({
page: async ({ browser }, use) => {
const adminPage = await browser.newPage();

Check warning on line 42 in openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Glossary/GlossaryWorkflow.spec.ts

View workflow job for this annotation

GitHub Actions / checkstyle

Prefer the `page` fixture (test.use({ storageState })) over browser.newPage() + manual login for single-user admin tests. For multi-user tests that need a second non-admin page, this warning is expected — no action needed
await adminUser.login(adminPage);
await use(adminPage);
await adminPage.close();
},
reviewer1Page: async ({ browser }, use) => {
const page = await browser.newPage();

Check warning on line 48 in openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Glossary/GlossaryWorkflow.spec.ts

View workflow job for this annotation

GitHub Actions / checkstyle

Prefer the `page` fixture (test.use({ storageState })) over browser.newPage() + manual login for single-user admin tests. For multi-user tests that need a second non-admin page, this warning is expected — no action needed
await reviewer1.login(page);
await use(page);
await page.close();
},
reviewer2Page: async ({ browser }, use) => {
const page = await browser.newPage();

Check warning on line 54 in openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Glossary/GlossaryWorkflow.spec.ts

View workflow job for this annotation

GitHub Actions / checkstyle

Prefer the `page` fixture (test.use({ storageState })) over browser.newPage() + manual login for single-user admin tests. For multi-user tests that need a second non-admin page, this warning is expected — no action needed
await reviewer2.login(page);
await use(page);
await page.close();
Expand Down Expand Up @@ -651,9 +652,8 @@

await expect(page.locator('[role="dialog"]')).toBeVisible();

await page.getByTestId('confirmation-text-input').fill('DELETE');

const deleteRes = page.waitForResponse('/api/v1/glossaryTerms/async/*');
await fillDeleteConfirmationIfPresent(page);
await page.getByTestId('confirm-button').click();
await deleteRes;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -169,8 +169,6 @@ test.describe(

await expect(page.locator('[role="dialog"].ant-modal')).toBeVisible();

await page.fill('[data-testid="confirmation-text-input"]', 'DELETE');

const deletePromise = page.waitForResponse(
(response) =>
response.request().method() === 'DELETE' &&
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,12 +96,20 @@

// RDF round-trip: with the triplestore enabled, exporting the glossary as an
// ontology reproduces the canonical concept IRI we imported.
const response = await apiContext.get(
`/api/v1/rdf/glossary/${glossary.responseData.id}/export?format=turtle`
);

expect(response.ok()).toBeTruthy();
expect(await response.text()).toContain(HCP_IRI);
// When RDF is disabled the export endpoint returns 503; skip the assertion
// rather than fail so the test remains useful in non-Fuseki environments.
const statusRes = await apiContext.get('/api/v1/rdf/status');
const rdfEnabled =
statusRes.ok() && (await statusRes.json()).enabled === true;

if (rdfEnabled) {
const response = await apiContext.get(
`/api/v1/rdf/glossary/${glossary.responseData.id}/export?format=turtle`
);

expect(response.ok()).toBeTruthy();
expect(await response.text()).toContain(HCP_IRI);
}

await afterAction();
});
Expand Down Expand Up @@ -137,7 +145,7 @@
test('hides Import Ontology from a user without glossary edit permission', async ({
browser,
}) => {
const userPage = await browser.newPage();

Check warning on line 148 in openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/OntologyImportRdf.spec.ts

View workflow job for this annotation

GitHub Actions / checkstyle

Prefer the `page` fixture (test.use({ storageState })) over browser.newPage() + manual login for single-user admin tests. For multi-user tests that need a second non-admin page, this warning is expected — no action needed
await consumerUser.login(userPage);
await redirectToHomePage(userPage);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,10 @@
import { expect } from '@playwright/test';
import { TableClass } from '../../support/entity/TableClass';
import { performAdminLogin } from '../../utils/admin';
import { waitForAllLoadersToDisappear } from '../../utils/entity';
import {
fillDeleteConfirmationIfPresent,
waitForAllLoadersToDisappear,
} from '../../utils/entity';
import {
addSampleDataViaApi,
navigateToSampleDataTab,
Expand Down Expand Up @@ -202,9 +205,8 @@ test.describe('Sample Data Tab - Download and Delete Functionality', () => {
});

await test.step('Type DELETE to enable confirm button', async () => {
await page.getByTestId('confirmation-text-input').fill('DELETE');

const confirmButton = page.getByTestId('confirm-button');
await page.getByTestId('confirmation-text-input').fill('DELETE');
await expect(confirmButton).toBeEnabled();
});

Expand Down Expand Up @@ -234,8 +236,6 @@ test.describe('Sample Data Tab - Download and Delete Functionality', () => {
});

await test.step('Type DELETE and confirm deletion', async () => {
await page.getByTestId('confirmation-text-input').fill('DELETE');

const deleteResponse = page.waitForResponse(
(response) =>
response
Expand All @@ -258,6 +258,7 @@ test.describe('Sample Data Tab - Download and Delete Functionality', () => {
response.status() === 200
);

await fillDeleteConfirmationIfPresent(page);
await page.getByTestId('confirm-button').click();
await deleteResponse;
await refetchResponse;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@
* limitations under the License.
*/
import { expect, test } from '@playwright/test';
import { DELETE_TERM } from '../../constant/common';
import { PLAYWRIGHT_BASIC_TEST_TAG_OBJ } from '../../constant/config';
import { GlobalSettingOptions } from '../../constant/settings';
import { redirectToHomePage, uuid } from '../../utils/common';
Expand Down Expand Up @@ -119,28 +118,12 @@ test.describe(

await page.click('[data-testid="delete-button-title"]');

await expect(page.locator('.ant-modal-header')).toContainText(
businessTeamName
);

await page.click(`[data-testid="hard-delete-option"]`);

await expect(
page.locator('[data-testid="confirm-button"]')
).toBeDisabled();

await page
.locator('[data-testid="confirmation-text-input"]')
.fill(DELETE_TERM);
await page.click(`[data-testid="hard-delete"]`);

const deleteResponse = page.waitForResponse(
`/api/v1/teams/*?hardDelete=true&recursive=true`
);

await expect(
page.locator('[data-testid="confirm-button"]')
).not.toBeDisabled();

await page.click('[data-testid="confirm-button"]');
await deleteResponse;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -166,13 +166,9 @@ test.describe('API service', PLAYWRIGHT_INGESTION_TAG_OBJ, () => {
await page.getByTestId('manage-button').click();
await page.getByTestId('delete-button').click();

await page.locator('[role="dialog"].ant-modal').waitFor();
await page.getByTestId('delete-modal').waitFor();

await expect(page.locator('[role="dialog"].ant-modal')).toBeVisible();

await page.click('[data-testid="hard-delete-option"]');
await page.check('[data-testid="hard-delete"]');
await page.fill('[data-testid="confirmation-text-input"]', 'DELETE');
await page.click('[data-testid="hard-delete"]');

const deleteResponse = page.waitForResponse(
'/api/v1/services/apiServices/async/*?hardDelete=true&recursive=true'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -227,21 +227,7 @@ test.describe('Explore Assets Discovery', () => {
await page.getByTestId('manage-button').click();
await page.getByTestId('delete-button').click();

await expect(
page
.locator('.ant-modal-title')
.getByText(
`Delete table "${
table1.entityResponseData.displayName ??
table1.entityResponseData.name
}"`
)
).toBeVisible();

await page.getByTestId('confirmation-text-input').click();
await page.getByTestId('confirmation-text-input').fill('DELETE');

await expect(page.getByTestId('confirm-button')).toBeEnabled();
await page.getByTestId('delete-modal').waitFor();

await page.getByTestId('confirm-button').click();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
*/

import { expect } from '@playwright/test';
import { DELETE_TERM } from '../../constant/common';
import { UserClass } from '../../support/user/UserClass';
import { performAdminLogin } from '../../utils/admin';
import { descriptionBox, uuid } from '../../utils/common';
Expand Down Expand Up @@ -139,23 +138,14 @@ test.describe.serial('User profile works after persona deletion', () => {
await page.getByTestId('manage-button').click();
await page.getByTestId('delete-button-title').click();

await expect(page.locator('.ant-modal-header')).toContainText(
PERSONA_DETAILS.displayName
);

await page.getByTestId('hard-delete-option').click();
await page.getByTestId('hard-delete').click();

const confirmButton = page.getByTestId('confirm-button');
await expect(confirmButton).toBeDisabled();

await page.getByTestId('confirmation-text-input').fill(DELETE_TERM);

const deleteResponse = page.waitForResponse(
`/api/v1/personas/*?hardDelete=true&recursive=false`
);

await expect(confirmButton).toBeEnabled();

await confirmButton.click();
await deleteResponse;

Expand Down
Loading
Loading