-
Notifications
You must be signed in to change notification settings - Fork 906
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into fetchAllSavedQueriesForSelectedTab
- Loading branch information
Showing
90 changed files
with
2,071 additions
and
793 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,7 @@ name: Run cypress tests | |
# trigger on every PR for all branches | ||
on: | ||
pull_request: | ||
branches: [ '**' ] | ||
branches: ['**'] | ||
paths-ignore: | ||
- '**/*.md' | ||
- '.lycheeignore' | ||
|
@@ -32,8 +32,6 @@ env: | |
TEST_REPO: ${{ inputs.test_repo != '' && inputs.test_repo || 'opensearch-project/opensearch-dashboards-functional-test' }} | ||
TEST_BRANCH: "${{ inputs.test_branch != '' && inputs.test_branch || github.base_ref }}" | ||
FTR_PATH: 'ftr' | ||
START_CMD: 'node ../scripts/opensearch_dashboards --dev --no-base-path --no-watch --savedObjects.maxImportPayloadBytes=10485760 --server.maxPayloadBytes=1759977 --logging.json=false --data.search.aggs.shardDelay.enabled=true --csp.warnLegacyBrowsers=false --uiSettings.overrides["query:enhancements:enabled"]=false' | ||
OPENSEARCH_SNAPSHOT_CMD: 'node ../scripts/opensearch snapshot -E cluster.routing.allocation.disk.threshold_enabled=false' | ||
CYPRESS_BROWSER: 'chromium' | ||
CYPRESS_VISBUILDER_ENABLED: true | ||
CYPRESS_DATASOURCE_MANAGEMENT_ENABLED: false | ||
|
@@ -42,18 +40,65 @@ env: | |
COMMENT_TAG: '[MANUAL CYPRESS TEST RUN RESULTS]' | ||
COMMENT_SUCCESS_MSG: ':white_check_mark: Cypress test run succeeded!' | ||
COMMENT_FAILURE_MSG: ':x: Cypress test run failed!' | ||
LATEST_VERSION: '2.17.0' | ||
|
||
jobs: | ||
cypress-tests: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
group: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10] | ||
include: | ||
# Standard test configs (groups 1-9) | ||
- group: 1 | ||
config: standard | ||
test_location: ftr | ||
- group: 2 | ||
config: standard | ||
test_location: ftr | ||
- group: 3 | ||
config: standard | ||
test_location: ftr | ||
- group: 4 | ||
config: standard | ||
test_location: ftr | ||
- group: 5 | ||
config: standard | ||
test_location: ftr | ||
- group: 6 | ||
config: standard | ||
test_location: ftr | ||
- group: 7 | ||
config: standard | ||
test_location: ftr | ||
- group: 8 | ||
config: standard | ||
test_location: ftr | ||
- group: 9 | ||
config: standard | ||
test_location: ftr | ||
# Query enhanced tests | ||
- group: 10 | ||
config: query_enhanced | ||
test_location: ftr | ||
# Dashboard tests | ||
- group: 11 | ||
config: dashboard | ||
test_location: source | ||
container: | ||
image: docker://opensearchstaging/ci-runner:ci-runner-rockylinux8-opensearch-dashboards-integtest-v2 | ||
options: --user 1001 | ||
env: | ||
START_CMD: ${{ matrix.config == 'query_enhanced' && | ||
'node ../scripts/opensearch_dashboards --dev --no-base-path --no-watch --savedObjects.maxImportPayloadBytes=10485760 --server.maxPayloadBytes=1759977 --logging.json=false --data.search.aggs.shardDelay.enabled=true --csp.warnLegacyBrowsers=false --uiSettings.overrides["query:enhancements:enabled"]=true --uiSettings.overrides[''home:useNewHomePage'']=true --data_source.enabled=true --opensearch.ignoreVersionMismatch=true' || | ||
matrix.config == 'dashboard' && | ||
'node scripts/opensearch_dashboards --dev --no-base-path --no-watch --savedObjects.maxImportPayloadBytes=10485760 --server.maxPayloadBytes=1759977 --logging.json=false --data.search.aggs.shardDelay.enabled=true' || | ||
'node ../scripts/opensearch_dashboards --dev --no-base-path --no-watch --savedObjects.maxImportPayloadBytes=10485760 --server.maxPayloadBytes=1759977 --logging.json=false --data.search.aggs.shardDelay.enabled=true --csp.warnLegacyBrowsers=false --uiSettings.overrides["query:enhancements:enabled"]=false' }} | ||
OPENSEARCH_SNAPSHOT_CMD: ${{ matrix.config == 'query_enhanced' && | ||
'/bin/bash -c "./opensearch-2.17.0/opensearch-tar-install.sh &"' || | ||
matrix.config == 'dashboard' && | ||
'node scripts/opensearch snapshot -E cluster.routing.allocation.disk.threshold_enabled=false' || | ||
'node ../scripts/opensearch snapshot -E cluster.routing.allocation.disk.threshold_enabled=false' }} | ||
# prevents extra Cypress installation progress messages | ||
CI: 1 | ||
# avoid warnings like "tput: No value for $TERM and no -T specified" | ||
|
@@ -117,7 +162,7 @@ jobs: | |
# Setup spec files for existing Functional Test repo cypress tests | ||
- name: Setup spec files | ||
if: ${{ inputs.specs == '' && matrix.group < 10 }} | ||
if: ${{ inputs.specs == '' && matrix.test_location == 'ftr' }} | ||
working-directory: ${{ env.FTR_PATH }} | ||
shell: bash | ||
run: | | ||
|
@@ -128,14 +173,26 @@ jobs: | |
done | ||
echo "SPEC=${FORMATTED_SPEC}" >> $GITHUB_ENV | ||
# Setup spec files for Dashboards in-house cypress tests | ||
- name: Setup spec files for Dashboards tests | ||
if: ${{ inputs.specs == '' && matrix.test_location == 'source' }} | ||
shell: bash | ||
run: | | ||
IFS="," read -a SPEC_ARRAY <<< $(yarn --silent osd:ciGroup${{ matrix.group }}) | ||
DASHBOARDS_SPEC='' | ||
for i in "${SPEC_ARRAY[@]}"; do | ||
DASHBOARDS_SPEC+="cypress/integration/core_opensearch_dashboards/${i}," | ||
done | ||
echo "DASHBOARDS_SPEC=${DASHBOARDS_SPEC}" >> $GITHUB_ENV | ||
- name: Get Cypress version | ||
if: ${{ matrix.group < 10 }} | ||
if: ${{ matrix.test_location == 'ftr' }} | ||
id: cypress_version | ||
run: | | ||
echo "name=cypress_version::$(cat ./${{ env.FTR_PATH }}/package.json | jq '.devDependencies.cypress' | tr -d '"')" >> $GITHUB_OUTPUT | ||
- name: Cache Cypress | ||
if: ${{ matrix.group < 10 }} | ||
if: ${{ matrix.test_location == 'ftr' }} | ||
id: cache-cypress | ||
uses: actions/cache@v1 | ||
with: | ||
|
@@ -146,70 +203,93 @@ jobs: | |
- run: npx cypress cache list | ||
- run: npx cypress cache path | ||
|
||
# Setup spec files for Dashboards in-house cypress tests | ||
- name: Setup spec files for Dashboards tests | ||
if: ${{ inputs.specs == '' && matrix.group > 9 }} | ||
# Run tests based on configuration | ||
- name: Run FT repo tests with no query enhancements | ||
if: matrix.test_location == 'ftr' && matrix.config == 'standard' | ||
uses: cypress-io/github-action@v2 | ||
with: | ||
working-directory: ${{ env.FTR_PATH }} | ||
start: ${{ env.OPENSEARCH_SNAPSHOT_CMD }}, ${{ env.START_CMD }} | ||
wait-on: 'http://localhost:9200, http://localhost:5601' | ||
command: yarn cypress:run-without-security --browser ${{ env.CYPRESS_BROWSER }} --spec ${{ env.SPEC }} | ||
|
||
- name: Download OpenSearch | ||
if: matrix.test_location == 'ftr' && matrix.config == 'query_enhanced' | ||
uses: suisei-cn/[email protected] | ||
with: | ||
url: https://artifacts.opensearch.org/releases/bundle/opensearch/${{ env.LATEST_VERSION }}/opensearch-${{ env.LATEST_VERSION }}-linux-x64.tar.gz | ||
|
||
- name: Extract OpenSearch | ||
if: matrix.test_location == 'ftr' && matrix.config == 'query_enhanced' | ||
run: | | ||
tar -xzf opensearch-*.tar.gz | ||
rm -f opensearch-*.tar.gz | ||
shell: bash | ||
|
||
- name: Remove security plugin | ||
if: matrix.test_location == 'ftr' && matrix.config == 'query_enhanced' | ||
run: | | ||
IFS="," read -a SPEC_ARRAY <<< $(yarn --silent osd:ciGroup${{ matrix.group }}) | ||
DASHBOARDS_SPEC='' | ||
for i in "${SPEC_ARRAY[@]}"; do | ||
DASHBOARDS_SPEC+="cypress/integration/core_opensearch_dashboards/${i}," | ||
done | ||
echo "DASHBOARDS_SPEC=${DASHBOARDS_SPEC}" >> $GITHUB_ENV | ||
/bin/bash -c "yes | ./opensearch-${{ env.LATEST_VERSION }}/bin/opensearch-plugin remove opensearch-security" | ||
shell: bash | ||
|
||
# Run FT repo tests | ||
- name: Run FT repo tests | ||
if: ${{ matrix.group < 10 }} | ||
- name: Run OpenSearch | ||
if: matrix.test_location == 'ftr' && matrix.config == 'query_enhanced' | ||
run: | | ||
/bin/bash -c "./opensearch-2.17.0/opensearch-tar-install.sh &" | ||
sleep 30 | ||
shell: bash | ||
|
||
- name: Run FT repo tests with query enhancements | ||
if: matrix.test_location == 'ftr' && matrix.config == 'query_enhanced' | ||
uses: cypress-io/github-action@v2 | ||
with: | ||
working-directory: ${{ env.FTR_PATH }} | ||
start: ${{ env.OPENSEARCH_SNAPSHOT_CMD }}, ${{ env.START_CMD }} | ||
start: ${{ env.START_CMD }} | ||
wait-on: 'http://localhost:9200, http://localhost:5601' | ||
command: yarn cypress:run-without-security --browser ${{ env.CYPRESS_BROWSER }} --spec ${{ env.SPEC }} | ||
|
||
# Clear Cypress Cache before running Dashboards tests | ||
- name: Clear Cypress Cache | ||
if: ${{ matrix.group > 9 }} | ||
if: matrix.test_location == 'source' | ||
run: npx cypress cache clear | ||
|
||
# Run Dashboards Cypress tests within the source repo | ||
- name: Run Dashboards Cypress tests | ||
if: ${{ matrix.group > 9 }} | ||
if: matrix.test_location == 'source' | ||
uses: cypress-io/github-action@v6 | ||
with: | ||
install-command: npx cypress install --force | ||
start: node scripts/opensearch snapshot -E cluster.routing.allocation.disk.threshold_enabled=false, node scripts/opensearch_dashboards --dev --no-base-path --no-watch --savedObjects.maxImportPayloadBytes=10485760 --server.maxPayloadBytes=1759977 --logging.json=false --data.search.aggs.shardDelay.enabled=true | ||
start: ${{ env.OPENSEARCH_SNAPSHOT_CMD }}, ${{ env.START_CMD }} | ||
wait-on: 'http://localhost:9200, http://localhost:5601' | ||
command: yarn cypress:run-without-security --browser ${{ env.CYPRESS_BROWSER }} --spec ${{ env.DASHBOARDS_SPEC }} | ||
|
||
# Screenshots are only captured on failure, will change this once we do visual regression tests | ||
- name: Upload FT repo screenshots | ||
uses: actions/upload-artifact@v3 | ||
if: failure() && (matrix.group < 10) | ||
if: failure() && matrix.test_location == 'ftr' | ||
with: | ||
name: ftr-cypress-screenshots | ||
path: ${{ env.FTR_PATH }}/cypress/screenshots | ||
retention-days: 1 | ||
|
||
- name: Upload FT repo videos | ||
uses: actions/upload-artifact@v3 | ||
if: always() && (matrix.group < 10) | ||
if: always() && matrix.test_location == 'ftr' | ||
with: | ||
name: ftr-cypress-videos | ||
path: ${{ env.FTR_PATH }}/cypress/videos | ||
retention-days: 1 | ||
|
||
- name: Upload FT repo results | ||
uses: actions/upload-artifact@v3 | ||
if: always() && (matrix.group < 10) | ||
if: always() && matrix.test_location == 'ftr' | ||
with: | ||
name: ftr-cypress-results | ||
path: ${{ env.FTR_PATH }}/cypress/results | ||
retention-days: 1 | ||
|
||
- name: Upload Dashboards screenshots | ||
if: failure() && (matrix.group > 9) | ||
if: failure() && matrix.test_location == 'source' | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: dashboards-cypress-screenshots | ||
|
@@ -218,15 +298,15 @@ jobs: | |
|
||
- name: Upload Dashboards repo videos | ||
uses: actions/upload-artifact@v3 | ||
if: always() && (matrix.group > 9) | ||
if: always() && matrix.test_location == 'source' | ||
with: | ||
name: dashboards-cypress-videos | ||
path: cypress/videos | ||
retention-days: 1 | ||
|
||
- name: Upload Dashboards repo results | ||
uses: actions/upload-artifact@v3 | ||
if: always() && (matrix.group > 9) | ||
if: always() && matrix.test_location == 'source' | ||
with: | ||
name: dashboards-cypress-results | ||
path: cypress/results | ||
|
@@ -245,7 +325,7 @@ jobs: | |
with: | ||
issue-number: ${{ inputs.pr_number }} | ||
comment-author: 'github-actions[bot]' | ||
body-includes: "${{ env.COMMENT_TAG }}" | ||
body-includes: '${{ env.COMMENT_TAG }}' | ||
|
||
- name: Add comment on the PR | ||
uses: peter-evans/create-or-update-comment@v3 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
fix: | ||
- Fix data source info is missing in default query when click Discover from other pages ([#8583](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/8583)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
refactor: | ||
- Update change access modal display name ([#8680](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/8680)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
feat: | ||
- Add support for async ppl to discover ([#8706](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/8706)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
fix: | ||
- Ensure save query loaded properly from asset ([#8707](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/8707)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
fix: | ||
- [Discover] Modify the search bar info box content for sql/ppl #8708 ([#8708](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/8708)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
refactor: | ||
- [discover] query editor and language selector state fixes ([#8712](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/8712)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
fix: | ||
-[Enhancement] Update auto-complete-api-with-mds ([#8713](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/8713)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
fix: | ||
- [Workspace] [Bug] Fix index pattern issue. ([#8718](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/8718)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
fix: | ||
- Generate short url with workspace info ([#8719](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/8719)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
fix: | ||
- Polling for PPL results; Saved dataset to saved queries ([#8724](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/8724)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
security: | ||
- [CVE-2024-48948] Bump `elliptic` from 6.5.7 to 6.6.0 ([#8742](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/8742)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
fix: | ||
- Fix error handling in query enhancement facet ([#8743](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/8743)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
fix: | ||
- Updates query and language if language is not supported by query data ([#8749](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/8749)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
fix: | ||
- Fix time field wrapping overlap on language change in Discover table ([#8755](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/8755)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
fix: | ||
- Fix error handling for ppl jobs API ([#8771](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/8771)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
fix: | ||
- Update async search response type ([#8781](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/8781)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
fix: | ||
- Staled closure inside chrome_service ([#8783](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/8783)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
fix: | ||
- [Discover] Makes cachign dataset options optional and configurable by the dataset type ([#8799](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/8799)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
fix: | ||
- Query Editor state sync issues in Discover ([#8803](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/8803)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.