Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
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 @@ -695,6 +695,59 @@ test.describe('Column Bulk Operations - Selection & Edit Drawer', () => {
});
});

test('should keep the tag select popup interactive inside the edit drawer', async ({
page,
}) => {
await test.step('Search, select a column, and open the edit drawer', async () => {
await searchColumn(page, sharedColumnName);
const checkbox = getColumnRowCheckbox(page, sharedColumnName);
await expect(checkbox).toBeVisible();
await checkbox.click();

const editButton = page.getByTestId('edit-button');
await expect(editButton).toBeEnabled();
await editButton.click();

await expect(
page.getByTestId('column-bulk-operations-form-drawer')
).toBeVisible();
});

await test.step('Open the tag select and verify its popup renders inside the drawer dialog', async () => {
const drawer = page.getByTestId('column-bulk-operations-form-drawer');

await drawer
.getByTestId('tags-field')
.locator('.ant-select-selector')
.click();

// Regression guard for the react-aria focus-scope bug: the Ant Select
// popup must render inside the drawer dialog (not document.body) so its
// options stay clickable and scrollable.
const dropdownOption = page
.locator(
'[role="dialog"] .async-select-list-dropdown .ant-select-item-option'
)
.first();
await expect(dropdownOption).toBeVisible();

await dropdownOption.click();

await expect(
page
.locator(
'[role="dialog"] .async-select-list-dropdown .ant-select-item-option-selected'
)
.first()
).toBeVisible();
});

await test.step('Close the drawer', async () => {
await page.keyboard.press('Escape');
await page.keyboard.press('Escape');
});
});

test('should show column count for multiple column selection', async ({
page,
}) => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ import { ClassificationClass } from '../../support/tag/ClassificationClass';
import { TagClass } from '../../support/tag/TagClass';
import { UserClass } from '../../support/user/UserClass';
import { performAdminLogin } from '../../utils/admin';
import { verifyDrawerAssetFilters } from '../../utils/assetSelection';
import { descriptionBox, redirectToHomePage } from '../../utils/common';
import {
addAssetsToDataProduct,
Expand Down Expand Up @@ -206,6 +207,55 @@ test.describe('Data Products', () => {
});
});

test('Data product add assets drawer quick filters are interactive', async ({
page,
}) => {
const dataProduct = new DataProduct([domain]);
const table = new TableClass();

const { apiContext, afterAction } = await performAdminLogin(
page.context().browser()!
);
await table.create(apiContext);
await table.patch({
apiContext,
patchData: [
{
op: 'add',
path: '/domains/0',
value: {
id: domain.responseData.id,
type: 'domain',
},
},
],
});
await dataProduct.create(apiContext);

try {
await sidebarClick(page, SidebarItem.DATA_PRODUCT);
await waitForAllLoadersToDisappear(page);
await selectDataProduct(page, dataProduct.data);

const assetRes = page.waitForResponse(
'/api/v1/search/query?q=&index=all&*'
);
await page.getByTestId('data-product-details-add-button').click();
await assetRes;

await page
.getByTestId('asset-selection-modal')
.waitFor({ state: 'visible' });
await waitForAllLoadersToDisappear(page);

await verifyDrawerAssetFilters(page);
} finally {
await dataProduct.delete(apiContext);
await table.delete(apiContext);
await afterAction();
}
});

test('Search Data Products', async ({ page }) => {
const dataProduct1 = new DataProduct([domain]);
const dataProduct2 = new DataProduct([domain]);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ import { TagClass } from '../../support/tag/TagClass';
import { TeamClass } from '../../support/team/TeamClass';
import { UserClass } from '../../support/user/UserClass';
import { performAdminLogin } from '../../utils/admin';
import { verifyDrawerAssetFilters } from '../../utils/assetSelection';
import {
clickOutside,
descriptionBox,
Expand Down Expand Up @@ -242,6 +243,39 @@ test.describe('Domains', () => {
await assetCleanup();
});

test('Domain add assets drawer quick filters are interactive', async ({
page,
}) => {
const { assetCleanup } = await setupAssetsForDomain(page);
const { apiContext, afterAction } = await getApiContext(page);
const filterDomain = new Domain();
await filterDomain.create(apiContext);

try {
await sidebarClick(page, SidebarItem.DOMAIN);
await selectDomain(page, filterDomain.data);
await waitForAllLoadersToDisappear(page);

const assetRes = page.waitForResponse(
'/api/v1/search/query?q=&index=all&*'
);
await page.getByTestId('domain-details-add-button').click();
await page.getByRole('menuitem', { name: 'Assets', exact: true }).click();
await assetRes;

await page
.getByTestId('asset-selection-modal')
.waitFor({ state: 'visible' });
await waitForAllLoadersToDisappear(page);

await verifyDrawerAssetFilters(page);
} finally {
await filterDomain.delete(apiContext);
await assetCleanup();
await afterAction();
}
});

test('Create DataProducts and add remove assets', async ({ page }) => {
test.slow(true);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ import { DashboardClass } from '../../support/entity/DashboardClass';
import { TableClass } from '../../support/entity/TableClass';
import { TopicClass } from '../../support/entity/TopicClass';
import { performAdminLogin } from '../../utils/admin';
import { verifyDrawerAssetFilters } from '../../utils/assetSelection';
import {
getApiContext,
redirectToHomePage,
Expand Down Expand Up @@ -634,7 +635,9 @@ test.describe('Input Output Ports', () => {
});
});

test('Port drawers show Entity Type quick filter', async ({ page }) => {
test('Port drawers allow selecting, scrolling and applying quick filters', async ({
page,
}) => {
const dataProduct = new DataProduct([domain]);

await test.step('Create data product with assets', async () => {
Expand All @@ -651,30 +654,26 @@ test.describe('Input Output Ports', () => {
await navigateToPortsTab(page);
});

await test.step('Verify Entity Type filter in input port drawer', async () => {
await test.step('Verify quick filters in input port drawer', async () => {
await page.getByTestId('add-input-port-button').click();
await page.getByTestId('asset-selection-modal').waitFor({
state: 'visible',
});
await waitForAllLoadersToDisappear(page);

await expect(
page.getByTestId('search-dropdown-Entity Type')
).toBeVisible();
await verifyDrawerAssetFilters(page);

await page.getByTestId('cancel-btn').click();
});

await test.step('Verify Entity Type filter in output port drawer', async () => {
await test.step('Verify quick filters in output port drawer', async () => {
await page.getByTestId('add-output-port-button').click();
await page.getByTestId('asset-selection-modal').waitFor({
state: 'visible',
});
await waitForAllLoadersToDisappear(page);

await expect(
page.getByTestId('search-dropdown-Entity Type')
).toBeVisible();
await verifyDrawerAssetFilters(page);

await page.getByTestId('cancel-btn').click();
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,13 @@ import { TagClass } from '../../support/tag/TagClass';
import { TeamClass } from '../../support/team/TeamClass';
import { UserClass } from '../../support/user/UserClass';
import { performAdminLogin } from '../../utils/admin';
import { applyAndClearFirstAssetFilterOption } from '../../utils/assetSelection';
import { getApiContext, redirectToHomePage, uuid } from '../../utils/common';
import { addMultiOwner, removeOwner } from '../../utils/entity';
import {
addMultiOwner,
removeOwner,
waitForAllLoadersToDisappear,
} from '../../utils/entity';
import { sidebarClick } from '../../utils/sidebar';
import {
addAssetsToTag,
Expand Down Expand Up @@ -216,6 +221,23 @@ test.describe('Tag Page with Admin Roles', () => {
await addAssetsToTag(adminPage, assets, tag1);
});

await test.step('Verify add asset modal filters are interactive', async () => {
const initialFetch = adminPage.waitForResponse(
'/api/v1/search/query?q=&index=all&from=0&size=25&deleted=false**'
);
await adminPage.getByTestId('data-classification-add-button').click();
await initialFetch;

await adminPage
.getByTestId('asset-selection-modal')
.waitFor({ state: 'visible' });
await waitForAllLoadersToDisappear(adminPage);

await applyAndClearFirstAssetFilterOption(adminPage, 'Entity Type');

await adminPage.getByTestId('cancel-btn').click();
});

await test.step('Verify EntityType Filter', async () => {
await verifyEntityTypeFilterInTagAssets(adminPage, assets);
});
Expand Down
Loading
Loading