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

[ES|QL] generate function validation tests #183343

Merged
merged 20 commits into from
May 16, 2024

Conversation

drewdaemon
Copy link
Contributor

@drewdaemon drewdaemon commented May 13, 2024

Summary

Close #182390

To test

You can test all aspects of the script by first making some changes to packages/kbn-esql-validation-autocomplete/src/validation/validation.test.ts

  • delete several tests from an existing function describe block ("block 1"—except don't choose "date_diff" since it has a bunch of custom tests)
  • delete another function describe block completely ("block 2")
  • change the expected result of several of the tests in a third function describe block ("block 3")

Then, run yarn maketests from within packages/kbn-esql-validation-autocomplete

Expected result

  • Block 1 should have the deleted tests restored
  • Block 2 should be restored entirely (though it may be moved in the tests file)
  • Block 3 should be untouched

Checklist

Comment on lines +374 to 379
"groupName": "Kibana ES|QL Team",
"matchPackageNames": ["recast"],
"reviewers": ["team:kibana-esql"],
"matchBaseBranches": ["main"],
"labels": ["Team:ESQL", "release_note:skip"],
"enabled": true
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is the change.

@drewdaemon
Copy link
Contributor Author

/ci

@drewdaemon
Copy link
Contributor Author

/ci

@drewdaemon drewdaemon changed the title [ES|QL] generate validation tests [ES|QL] generate function validation tests May 15, 2024
@drewdaemon
Copy link
Contributor Author

/ci

@drewdaemon
Copy link
Contributor Author

@elasticmachine merge upstream

@drewdaemon
Copy link
Contributor Author

/ci

@drewdaemon drewdaemon marked this pull request as ready for review May 15, 2024 20:32
@drewdaemon drewdaemon requested a review from a team as a code owner May 15, 2024 20:32
@drewdaemon drewdaemon added release_note:skip Skip the PR/issue when compiling release notes Team:ESQL ES|QL related features in Kibana labels May 15, 2024
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-esql (Team:ESQL)

@drewdaemon drewdaemon added the technical debt Improvement of the software architecture and operational architecture label May 15, 2024
@kibana-ci
Copy link
Collaborator

💛 Build succeeded, but was flaky

Failed CI Steps

Test Failures

  • [job] [logs] FTR Configs #88 / dashboard Reporting Dashboard Reporting Screenshots Preserve Layout downloads a PDF file with saved search given EuiDataGrid enabled

Metrics [docs]

✅ unchanged

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

@stratoula stratoula requested a review from a team May 16, 2024 05:48
@stratoula
Copy link
Contributor

Fantastic job 👏

We are adding a new npm package @elastic/kibana-operations I am not sure if you also want to have a look.

@drewdaemon drewdaemon enabled auto-merge (squash) May 16, 2024 13:56
@drewdaemon drewdaemon merged commit c4ef9bd into elastic:main May 16, 2024
38 checks passed
@kibanamachine kibanamachine added the backport:skip This commit does not require backporting label May 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:skip This commit does not require backporting Feature:ES|QL release_note:skip Skip the PR/issue when compiling release notes Team:ESQL ES|QL related features in Kibana technical debt Improvement of the software architecture and operational architecture v8.15.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[ES|QL] separate test generation logic from validation tests
6 participants