mirror of
https://github.com/open-metadata/OpenMetadata.git
synced 2025-08-31 20:51:26 +00:00
cypress: fixed AUT cypress failure part 2 (#16243)
* cypress: fixed AUT cypress failure part 2 * fixed query cypress * reverting logs
This commit is contained in:
parent
08564037e7
commit
2e52475b68
@ -209,16 +209,6 @@ describe('Query Entity', { tags: 'DataAssets' }, () => {
|
||||
});
|
||||
|
||||
it('Verify query filter', () => {
|
||||
interceptURL(
|
||||
'GET',
|
||||
'/api/v1/search/query?*index=user_search_index,team_search_index*',
|
||||
'searchOwner'
|
||||
);
|
||||
interceptURL(
|
||||
'GET',
|
||||
'/api/v1/search/query?*index=tag_search_index*',
|
||||
'searchTag'
|
||||
);
|
||||
visitEntityDetailsPage({
|
||||
term: DATA.term,
|
||||
serviceName: DATA.serviceName,
|
||||
@ -226,27 +216,52 @@ describe('Query Entity', { tags: 'DataAssets' }, () => {
|
||||
});
|
||||
cy.get('[data-testid="table_queries"]').click();
|
||||
verifyResponseStatusCode('@fetchQuery', 200);
|
||||
const userName = `${user.firstName}${user.lastName}`;
|
||||
interceptURL(
|
||||
'GET',
|
||||
`/api/v1/search/query?*${encodeURI(
|
||||
userName
|
||||
)}*index=user_search_index,team_search_index*`,
|
||||
'searchUserName'
|
||||
);
|
||||
queryFilters({
|
||||
filter: `${user.firstName}${user.lastName}`,
|
||||
apiKey: '@searchOwner',
|
||||
apiKey: '@searchUserName',
|
||||
key: 'Owner',
|
||||
});
|
||||
interceptURL(
|
||||
'GET',
|
||||
`/api/v1/search/query?*${encodeURI(
|
||||
DATA.owner
|
||||
)}*index=user_search_index,team_search_index*`,
|
||||
'searchOwner'
|
||||
);
|
||||
cy.get('[data-testid="no-data-placeholder"]').should('be.visible');
|
||||
queryFilters({
|
||||
filter: DATA.owner,
|
||||
apiKey: '@searchOwner',
|
||||
key: 'Owner',
|
||||
});
|
||||
interceptURL(
|
||||
'GET',
|
||||
'/api/v1/search/query?*None*index=tag_search_index*',
|
||||
'noneTagSearch'
|
||||
);
|
||||
cy.get('[data-testid="query-card"]').should('have.length.above', 0);
|
||||
queryFilters({
|
||||
filter: 'None',
|
||||
apiKey: '@searchTag',
|
||||
apiKey: '@noneTagSearch',
|
||||
key: 'Tag',
|
||||
});
|
||||
interceptURL(
|
||||
'GET',
|
||||
`/api/v1/search/query?*${DATA.tag}*index=tag_search_index*`,
|
||||
'personalTagSearch'
|
||||
);
|
||||
cy.get('[data-testid="no-data-placeholder"]').should('be.visible');
|
||||
queryFilters({
|
||||
filter: DATA.tag,
|
||||
apiKey: '@searchTag',
|
||||
apiKey: '@personalTagSearch',
|
||||
key: 'Tag',
|
||||
});
|
||||
cy.get('[data-testid="query-card"]').should('have.length.above', 0);
|
||||
|
@ -145,7 +145,7 @@ describe('Data Insight feature', { tags: 'Observability' }, () => {
|
||||
|
||||
// Adding a manual wait to allow some time between deploying the pipeline and triggering it
|
||||
// eslint-disable-next-line cypress/no-unnecessary-waiting
|
||||
cy.wait(1000);
|
||||
cy.wait(2000);
|
||||
cy.get('[data-testid="run-now-button"]').click();
|
||||
verifyResponseStatusCode('@triggerPipeline', 200);
|
||||
cy.reload();
|
||||
@ -260,7 +260,7 @@ describe('Data Insight feature', { tags: 'Observability' }, () => {
|
||||
cy.sidebarClick(SidebarItem.DATA_INSIGHT);
|
||||
verifyResponseStatusCode('@dataInsightsChart', 200);
|
||||
cy.get('[data-menu-id*="kpi"]').click();
|
||||
verifyResponseStatusCode('@dataInsightsChart', 200);
|
||||
verifyResponseStatusCode('@getKpi', 200);
|
||||
KPI_DATA.map((data) => {
|
||||
cy.get(`[data-testid="edit-action-${data.displayName}"]`).click();
|
||||
verifyResponseStatusCode('@fetchKpiByName', 200);
|
||||
|
@ -44,7 +44,9 @@ describe(
|
||||
cy.get('[data-testid="cron-type"]').click();
|
||||
cy.get('.rc-virtual-list [title="Day"]').click();
|
||||
cy.get('[data-testid="hour-options"]').click();
|
||||
cy.get('[title="06"]').click();
|
||||
cy.get('.ant-select-dropdown [title="06"]').click();
|
||||
cy.get('[data-testid="minute-options"]').click();
|
||||
cy.get('.ant-select-dropdown [title="00"]').click();
|
||||
cy.get('.ant-modal-body [data-testid="deploy-button"]').click();
|
||||
verifyResponseStatusCode('@updateApplication', 200);
|
||||
cy.get('[data-testid="cron-string"]').should('contain', 'At 06:00 AM');
|
||||
|
@ -11,6 +11,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
// eslint-disable-next-line spaced-comment
|
||||
import { interceptURL, verifyResponseStatusCode } from '../../common/common';
|
||||
import UsersTestClass from '../../common/Entities/UserClass';
|
||||
import { visitEntityDetailsPage } from '../../common/Utils/Entity';
|
||||
import { getToken } from '../../common/Utils/LocalStorage';
|
||||
@ -20,10 +21,10 @@ import {
|
||||
removeOwner,
|
||||
} from '../../common/Utils/Owner';
|
||||
import {
|
||||
DATA_CONSUMER_ROLE,
|
||||
DATA_STEWARD_ROLE,
|
||||
cleanupPolicies,
|
||||
createRoleViaREST,
|
||||
DATA_CONSUMER_ROLE,
|
||||
DATA_STEWARD_ROLE,
|
||||
} from '../../common/Utils/Policy';
|
||||
import {
|
||||
addUser,
|
||||
@ -35,8 +36,6 @@ import {
|
||||
updateExpiration,
|
||||
visitUserListPage,
|
||||
} from '../../common/Utils/Users';
|
||||
import { interceptURL, verifyResponseStatusCode } from '../../common/common';
|
||||
import { EntityType, SidebarItem } from '../../constants/Entity.interface';
|
||||
import {
|
||||
BASE_URL,
|
||||
DELETE_ENTITY,
|
||||
@ -44,6 +43,7 @@ import {
|
||||
ID,
|
||||
uuid,
|
||||
} from '../../constants/constants';
|
||||
import { EntityType, SidebarItem } from '../../constants/Entity.interface';
|
||||
import {
|
||||
GlobalSettingOptions,
|
||||
SETTINGS_OPTIONS_PATH,
|
||||
|
Loading…
x
Reference in New Issue
Block a user