Fix(ui): Flaky Tier Count (#22791)

* fixed tier flaky

* removed unncessary items
This commit is contained in:
Dhruv Parmar 2025-08-07 02:41:41 +05:30 committed by GitHub
parent 42572747ed
commit 355a579d35
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
6 changed files with 40 additions and 22 deletions

View File

@ -32,3 +32,31 @@ export const NAME_MAX_LENGTH_VALIDATION_ERROR =
'Name size must be between 1 and 128';
export const DELETE_TERM = 'DELETE';
export const COMMON_TIER_TAG = [
{
id: 'd9b52629-0288-4d29-99bf-ecdd1713d285',
name: 'Tier1',
fullyQualifiedName: 'Tier.Tier1',
},
{
id: 'fafc6234-f036-4e02-9666-20e30ceb593b',
name: 'Tier2',
fullyQualifiedName: 'Tier.Tier2',
},
{
id: 'de9dba4b-a92c-4a58-a3d8-93e72f315a29',
name: 'Tier3',
fullyQualifiedName: 'Tier.Tier3',
},
{
id: '9ee864ea-d8e6-4ecc-9017-57d1e72e501e',
name: 'Tier4',
fullyQualifiedName: 'Tier.Tier4',
},
{
id: '36c08b3b-85b5-460b-86b7-806857314883',
name: 'Tier5',
fullyQualifiedName: 'Tier.Tier5',
},
];

View File

@ -11,6 +11,7 @@
* limitations under the License.
*/
import test from '@playwright/test';
import { COMMON_TIER_TAG } from '../../constant/common';
import { SidebarItem } from '../../constant/sidebar';
import { EntityDataClass } from '../../support/entity/EntityDataClass';
import { EntityDataClassCreationConfig } from '../../support/entity/EntityDataClass.interface';
@ -141,7 +142,7 @@ test.describe('Advanced Search', { tag: '@advanced-search' }, () => {
await EntityDataClass.topic1.visitEntityPage(page);
await assignTier(
page,
EntityDataClass.tierTag1.data.displayName,
COMMON_TIER_TAG[0].name,
EntityDataClass.topic1.endpoint
);
@ -149,7 +150,7 @@ test.describe('Advanced Search', { tag: '@advanced-search' }, () => {
await EntityDataClass.topic2.visitEntityPage(page);
await assignTier(
page,
EntityDataClass.tierTag2.data.displayName,
COMMON_TIER_TAG[1].name,
EntityDataClass.topic2.endpoint
);
@ -161,8 +162,8 @@ test.describe('Advanced Search', { tag: '@advanced-search' }, () => {
],
'tags.tagFQN': ['PersonalData.Personal', 'PII.None'],
'tier.tagFQN': [
EntityDataClass.tierTag1.responseData.fullyQualifiedName,
EntityDataClass.tierTag2.responseData.fullyQualifiedName,
COMMON_TIER_TAG[0].fullyQualifiedName,
COMMON_TIER_TAG[1].fullyQualifiedName,
],
'service.displayName.keyword': [
EntityDataClass.table1.service.name,

View File

@ -12,6 +12,7 @@
*/
import { expect, Page, test as base } from '@playwright/test';
import { isUndefined } from 'lodash';
import { COMMON_TIER_TAG } from '../../constant/common';
import { CustomPropertySupportedEntityList } from '../../constant/customProperty';
import { DATA_CONSUMER_RULES } from '../../constant/permission';
import { PolicyClass } from '../../support/access-control/PoliciesClass';
@ -231,8 +232,8 @@ entities.forEach((EntityClass) => {
await entity.tier(
page,
'Tier1',
EntityDataClass.tierTag1.responseData.displayName,
EntityDataClass.tierTag1.responseData.fullyQualifiedName,
COMMON_TIER_TAG[2].name,
COMMON_TIER_TAG[2].fullyQualifiedName,
entity
);
});

View File

@ -12,6 +12,7 @@
*/
import { expect, Page, test as base } from '@playwright/test';
import { isUndefined } from 'lodash';
import { COMMON_TIER_TAG } from '../../constant/common';
import { ApiEndpointClass } from '../../support/entity/ApiEndpointClass';
import { ContainerClass } from '../../support/entity/ContainerClass';
import { DashboardClass } from '../../support/entity/DashboardClass';
@ -100,11 +101,7 @@ entities.forEach((EntityClass) => {
});
test('Tier Add, Update and Remove', async ({ page }) => {
await entity.tier(
page,
'Tier1',
EntityDataClass.tierTag1.data.displayName
);
await entity.tier(page, COMMON_TIER_TAG[0].name, COMMON_TIER_TAG[3].name);
});
test('Update description', async ({ page }) => {

View File

@ -12,6 +12,7 @@
*/
import { Page, test as base } from '@playwright/test';
import { isUndefined } from 'lodash';
import { COMMON_TIER_TAG } from '../../constant/common';
import { ApiEndpointClass } from '../../support/entity/ApiEndpointClass';
import { ContainerClass } from '../../support/entity/ContainerClass';
import { DashboardClass } from '../../support/entity/DashboardClass';
@ -115,11 +116,7 @@ entities.forEach((EntityClass) => {
});
test('Tier Add, Update and Remove', async ({ page }) => {
await entity.tier(
page,
'Tier1',
EntityDataClass.tierTag1.data.displayName
);
await entity.tier(page, 'Tier1', COMMON_TIER_TAG[0].name);
});
test('Update description', async ({ page }) => {

View File

@ -55,8 +55,6 @@ export class EntityDataClass {
static readonly user3 = new UserClass();
static readonly team1 = new TeamClass();
static readonly team2 = new TeamClass();
static readonly tierTag1 = new TagClass({ classification: 'Tier' });
static readonly tierTag2 = new TagClass({ classification: 'Tier' });
static readonly certificationTag1 = new TagClass({
classification: 'Certification',
});
@ -126,8 +124,6 @@ export class EntityDataClass {
this.user3.create(apiContext),
this.team1.create(apiContext),
this.team2.create(apiContext),
this.tierTag1.create(apiContext),
this.tierTag2.create(apiContext),
this.certificationTag1.create(apiContext),
this.certificationTag2.create(apiContext),
this.classification1.create(apiContext),
@ -243,8 +239,6 @@ export class EntityDataClass {
this.user3.delete(apiContext),
this.team1.delete(apiContext),
this.team2.delete(apiContext),
this.tierTag1.delete(apiContext),
this.tierTag2.delete(apiContext),
this.certificationTag1.delete(apiContext),
this.certificationTag2.delete(apiContext),
this.classification1.delete(apiContext),