Skip to content

Commit

Permalink
[Follow-up #9386] Add TODO and omit for hide missing values for SQL a…
Browse files Browse the repository at this point in the history
…nd PPL (#9402)

Follow-up PR:
#9386

Signed-off-by: Anan <ananzh@amazon.com>
  • Loading branch information
ananzh authored Feb 17, 2025
1 parent c220796 commit 2b6e7bf
Showing 1 changed file with 14 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@
*/

import { DatasetTypes, PATHS, BASE_PATH } from '../../../../../utils/constants';

import {
DATASOURCE_NAME,
INDEX_PATTERN_WITH_TIME_1,
INDEX_WITH_TIME_1,
QueryLanguages,
} from '../../../../../utils/apps/query_enhancements/constants';
import {
generateAllTestConfigurations,
Expand Down Expand Up @@ -363,11 +363,19 @@ export const runSideBarTests = () => {
);
}

cy.getElementByTestId('missingSwitch').click();
sidebarFields.missingFields.forEach((fieldName) => {
cy.getElementByTestId(`field-${fieldName}`).should('be.visible');
});
cy.getElementByTestId('missingSwitch').click();
// TODO: Hide missing fields switch is not working for SQL and PPL.
// SQL and PPL add all mapped fields to the sidebar, including missing fields.
// https://github.com/opensearch-project/OpenSearch-Dashboards/issues/9342
if (
config.language === QueryLanguages.DQL.name ||
config.language === QueryLanguages.Lucene.name
) {
cy.getElementByTestId('missingSwitch').click();
sidebarFields.missingFields.forEach((fieldName) => {
cy.getElementByTestId(`field-${fieldName}`).should('be.visible');
});
cy.getElementByTestId('missingSwitch').click();
}

sideBar.verifyNumberOfActiveFilters(0);
cy.getElementByTestId('aggregatable-true').parent().click();
Expand Down

0 comments on commit 2b6e7bf

Please sign in to comment.