Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[TESTID-140 New Test Suites] Top Values and Filter Sidebar Fields By Type functionality for Discover #9386

Merged
merged 7 commits into from
Feb 17, 2025

Conversation

ArgusLi
Copy link
Contributor

@ArgusLi ArgusLi commented Feb 13, 2025

Description

Adds a Cypress test spec for the Top Values and Filter Sidebar Fields by Type functionality for the Discover page.

Issues Resolved

closes #8946

Screenshot

sidebar_1.mp4
sidebar_2.mp4
sidebar_3.mp4
sidebar_4.mp4
sidebar_5.mp4
sidebar_6.mp4
sidebar_7.mp4
sidebar_8.mp4
sidebar_9.mp4
sidebar_10.mp4
sidebar_11.mp4
sidebar_12.mp4

Testing the changes

With OSD running, run yarn run cypress open. In E2E specs, you will see sidebar.spec.js. Run the test spec.

Changelog

  • test: Add Top Values and Filter Sidebar Fields by Type testing for the Discover Page.

Copy link

codecov bot commented Feb 13, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 61.71%. Comparing base (4d55b4d) to head (8705a3e).
Report is 4 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #9386      +/-   ##
==========================================
- Coverage   61.72%   61.71%   -0.01%     
==========================================
  Files        3817     3817              
  Lines       91860    91860              
  Branches    14551    14551              
==========================================
- Hits        56697    56695       -2     
- Misses      31507    31508       +1     
- Partials     3656     3657       +1     
Flag Coverage Δ
Linux_1 29.00% <ø> (ø)
Linux_2 56.46% <ø> (ø)
Linux_3 39.19% <ø> (-0.01%) ⬇️
Linux_4 28.90% <ø> (ø)
Windows_1 29.01% <ø> (ø)
Windows_2 56.41% <ø> (ø)
Windows_3 39.20% <ø> (ø)
Windows_4 28.90% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@ananzh ananzh added discover_2.0-test Issues that are specific to the Discover 2.0 testing initiative backport 2.x v2.20.0 labels Feb 14, 2025
}

cy.getElementByTestId('missingSwitch').click();
sidebarFields.missingFields.forEach((fieldName) => {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Currently hide missing values only work for DQL and Lucene #9342

Though the tests passed, it is due to PPL and SQL will display all mapped fields including missing values fields in the side panel. It is a false positive. Will submit a PR to update this part.

@ananzh ananzh changed the title Top Values and Filter Sidebar Fields By Type functionality for Discover [TESTID-140 New Test Suites] Top Values and Filter Sidebar Fields By Type functionality for Discover Feb 17, 2025
@ananzh ananzh merged commit c220796 into opensearch-project:main Feb 17, 2025
79 of 80 checks passed
@opensearch-trigger-bot
Copy link
Contributor

The backport to 2.x failed:

The process '/usr/bin/git' failed with exit code 128

To backport manually, run these commands in your terminal:

# Navigate to the root of your repository
cd $(git rev-parse --show-toplevel)
# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add ../.worktrees/OpenSearch-Dashboards/backport-2.x 2.x
# Navigate to the new working tree
pushd ../.worktrees/OpenSearch-Dashboards/backport-2.x
# Create a new branch
git switch --create backport/backport-9386-to-2.x
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 c220796ad4ac6d48d2818835706d7cee71a09c2d
# Push it to GitHub
git push --set-upstream origin backport/backport-9386-to-2.x
# Go back to the original working tree
popd
# Delete the working tree
git worktree remove ../.worktrees/OpenSearch-Dashboards/backport-2.x

Then, create a pull request where the base branch is 2.x and the compare/head branch is backport/backport-9386-to-2.x.

ananzh added a commit to ananzh/OpenSearch-Dashboards that referenced this pull request Feb 17, 2025
ananzh added a commit that referenced this pull request Feb 17, 2025
sumukhswamy pushed a commit to sumukhswamy/OpenSearch-Dashboards that referenced this pull request Feb 18, 2025
…Type functionality for Discover (opensearch-project#9386)

* Finish top values test scenario.

Signed-off-by: Argus Li <[email protected]>

* Add filtering fields by type

Signed-off-by: Argus Li <[email protected]>

* Changeset file for PR opensearch-project#9386 created/updated

* Fix Datasource url

Signed-off-by: Argus Li <[email protected]>

---------

Signed-off-by: Argus Li <[email protected]>
Co-authored-by: opensearch-changeset-bot[bot] <154024398+opensearch-changeset-bot[bot]@users.noreply.github.com>
sumukhswamy pushed a commit to sumukhswamy/OpenSearch-Dashboards that referenced this pull request Feb 18, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport 2.x discover_2.0-test Issues that are specific to the Discover 2.0 testing initiative failed backport v2.20.0 valued-contributor
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Results Display and Interaction in Table, Side panel] TESTID-140: Side bar
4 participants