Skip to content

[ResponseOps] Fixes embeddable alerts panel flaky test#227390

Merged
cnasikas merged 6 commits intoelastic:mainfrom
cnasikas:fix_220807
Jul 12, 2025
Merged

[ResponseOps] Fixes embeddable alerts panel flaky test#227390
cnasikas merged 6 commits intoelastic:mainfrom
cnasikas:fix_220807

Conversation

@cnasikas
Copy link
Member

@cnasikas cnasikas commented Jul 10, 2025

Summary

I changed the code to use API calls to create resources like rules and install the data sample data instead of using the UI. I also fixed a small issue with the time range selector that caused the tests to fail.

Fixes: #220807.

Checklist

Check the PR satisfies following conditions.

Reviewers should verify this PR satisfies this list as well.

@cnasikas cnasikas self-assigned this Jul 10, 2025
@cnasikas cnasikas added release_note:skip Skip the PR/issue when compiling release notes backport:version Backport to applied version labels v9.1.0 v8.19.0 v9.2.0 labels Jul 10, 2025
@kibanamachine
Copy link
Contributor

Flaky Test Runner Stats

🎉 All tests passed! - kibana-flaky-test-suite-runner#8583

[✅] x-pack/platform/test/functional_with_es_ssl/apps/embeddable_alerts_table/config.ts: 200/200 tests passed.

see run history

@kibanamachine
Copy link
Contributor

Flaky Test Runner Stats

🟠 Some tests failed. - kibana-flaky-test-suite-runner#8588

[❌] x-pack/platform/test/functional_with_es_ssl/apps/embeddable_alerts_table/config.ts: 0/200 tests passed.

see run history

const retryTimeout = config.get('timeouts.try');
const es = getService('es');

const createEsQueryRule = async (index: string, solution: 'stack' | 'observability') => {
Copy link
Member Author

Choose a reason for hiding this comment

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

I moved the util functions to the bottom.

@cnasikas cnasikas marked this pull request as ready for review July 11, 2025 12:09
@cnasikas cnasikas requested a review from a team as a code owner July 11, 2025 12:09
Copy link
Contributor

@js-jankisalvi js-jankisalvi left a comment

Choose a reason for hiding this comment

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

Looks good 👍

};
describe('Embeddable alerts panel', () => {
before(async () => {
await sampleData.testResources.installAllKibanaSampleData();
Copy link
Contributor

Choose a reason for hiding this comment

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

Nice, I didn't know we have sampleData service 😅

@kibanamachine
Copy link
Contributor

Flaky Test Runner Stats

🟠 Some tests failed. - kibana-flaky-test-suite-runner#8620

[❌] x-pack/platform/test/functional_with_es_ssl/apps/embeddable_alerts_table/config.ts: 174/200 tests passed.

see run history

@elasticmachine
Copy link
Contributor

💛 Build succeeded, but was flaky

Failed CI Steps

Test Failures

  • [job] [logs] FTR Configs #39 / Search solution tests Search Home page Solution Nav - Search search home page with existing indices "before each" hook for "renders Elasticsearch Documentation content"

Metrics [docs]

✅ unchanged

History

cc @cnasikas

@kibanamachine
Copy link
Contributor

Flaky Test Runner Stats

🎉 All tests passed! - kibana-flaky-test-suite-runner#8634

[✅] x-pack/platform/test/functional_with_es_ssl/apps/embeddable_alerts_table/config.ts: 200/200 tests passed.

see run history

@cnasikas cnasikas merged commit 45db4ad into elastic:main Jul 12, 2025
13 checks passed
@cnasikas cnasikas deleted the fix_220807 branch July 12, 2025 10:58
@kibanamachine
Copy link
Contributor

Starting backport for target branches: 8.19, 9.1

https://github.com/elastic/kibana/actions/runs/16237313252

kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Jul 12, 2025
## Summary

I changed the code to use API calls to create resources like rules and
install the data sample data instead of using the UI. I also fixed a
small issue with the time range selector that caused the tests to fail.

Fixes: elastic#220807.

### Checklist

Check the PR satisfies following conditions.

Reviewers should verify this PR satisfies this list as well.

- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios

(cherry picked from commit 45db4ad)
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Jul 12, 2025
## Summary

I changed the code to use API calls to create resources like rules and
install the data sample data instead of using the UI. I also fixed a
small issue with the time range selector that caused the tests to fail.

Fixes: elastic#220807.

### Checklist

Check the PR satisfies following conditions.

Reviewers should verify this PR satisfies this list as well.

- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios

(cherry picked from commit 45db4ad)
@kibanamachine
Copy link
Contributor

💚 All backports created successfully

Status Branch Result
8.19
9.1

Note: Successful backport PRs will be merged automatically after passing CI.

Questions ?

Please refer to the Backport tool documentation

kibanamachine added a commit that referenced this pull request Jul 12, 2025
#227740)

# Backport

This will backport the following commits from `main` to `9.1`:
- [[ResponseOps] Fixes embeddable alerts panel flaky test
(#227390)](#227390)

<!--- Backport version: 9.6.6 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sorenlouv/backport)

<!--BACKPORT [{"author":{"name":"Christos
Nasikas","email":"christos.nasikas@elastic.co"},"sourceCommit":{"committedDate":"2025-07-12T10:58:39Z","message":"[ResponseOps]
Fixes embeddable alerts panel flaky test (#227390)\n\n## Summary\n\nI
changed the code to use API calls to create resources like rules
and\ninstall the data sample data instead of using the UI. I also fixed
a\nsmall issue with the time range selector that caused the tests to
fail.\n\nFixes: https://github.com/elastic/kibana/issues/220807.\n\n###
Checklist\n\nCheck the PR satisfies following conditions. \n\nReviewers
should verify this PR satisfies this list as well.\n\n- [x] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common
scenarios","sha":"45db4add3c3365c9538adf35529577462e5baf6d","branchLabelMapping":{"^v9.2.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","backport:version","v9.1.0","v8.19.0","v9.2.0"],"title":"[ResponseOps]
Fixes embeddable alerts panel flaky
test","number":227390,"url":"https://github.com/elastic/kibana/pull/227390","mergeCommit":{"message":"[ResponseOps]
Fixes embeddable alerts panel flaky test (#227390)\n\n## Summary\n\nI
changed the code to use API calls to create resources like rules
and\ninstall the data sample data instead of using the UI. I also fixed
a\nsmall issue with the time range selector that caused the tests to
fail.\n\nFixes: https://github.com/elastic/kibana/issues/220807.\n\n###
Checklist\n\nCheck the PR satisfies following conditions. \n\nReviewers
should verify this PR satisfies this list as well.\n\n- [x] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common
scenarios","sha":"45db4add3c3365c9538adf35529577462e5baf6d"}},"sourceBranch":"main","suggestedTargetBranches":["9.1","8.19"],"targetPullRequestStates":[{"branch":"9.1","label":"v9.1.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.19","label":"v8.19.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v9.2.0","branchLabelMappingKey":"^v9.2.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/227390","number":227390,"mergeCommit":{"message":"[ResponseOps]
Fixes embeddable alerts panel flaky test (#227390)\n\n## Summary\n\nI
changed the code to use API calls to create resources like rules
and\ninstall the data sample data instead of using the UI. I also fixed
a\nsmall issue with the time range selector that caused the tests to
fail.\n\nFixes: https://github.com/elastic/kibana/issues/220807.\n\n###
Checklist\n\nCheck the PR satisfies following conditions. \n\nReviewers
should verify this PR satisfies this list as well.\n\n- [x] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common
scenarios","sha":"45db4add3c3365c9538adf35529577462e5baf6d"}}]}]
BACKPORT-->

Co-authored-by: Christos Nasikas <christos.nasikas@elastic.co>
kibanamachine added a commit that referenced this pull request Jul 13, 2025
… (#227739)

# Backport

This will backport the following commits from `main` to `8.19`:
- [[ResponseOps] Fixes embeddable alerts panel flaky test
(#227390)](#227390)

<!--- Backport version: 9.6.6 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sorenlouv/backport)

<!--BACKPORT [{"author":{"name":"Christos
Nasikas","email":"christos.nasikas@elastic.co"},"sourceCommit":{"committedDate":"2025-07-12T10:58:39Z","message":"[ResponseOps]
Fixes embeddable alerts panel flaky test (#227390)\n\n## Summary\n\nI
changed the code to use API calls to create resources like rules
and\ninstall the data sample data instead of using the UI. I also fixed
a\nsmall issue with the time range selector that caused the tests to
fail.\n\nFixes: https://github.com/elastic/kibana/issues/220807.\n\n###
Checklist\n\nCheck the PR satisfies following conditions. \n\nReviewers
should verify this PR satisfies this list as well.\n\n- [x] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common
scenarios","sha":"45db4add3c3365c9538adf35529577462e5baf6d","branchLabelMapping":{"^v9.2.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","backport:version","v9.1.0","v8.19.0","v9.2.0"],"title":"[ResponseOps]
Fixes embeddable alerts panel flaky
test","number":227390,"url":"https://github.com/elastic/kibana/pull/227390","mergeCommit":{"message":"[ResponseOps]
Fixes embeddable alerts panel flaky test (#227390)\n\n## Summary\n\nI
changed the code to use API calls to create resources like rules
and\ninstall the data sample data instead of using the UI. I also fixed
a\nsmall issue with the time range selector that caused the tests to
fail.\n\nFixes: https://github.com/elastic/kibana/issues/220807.\n\n###
Checklist\n\nCheck the PR satisfies following conditions. \n\nReviewers
should verify this PR satisfies this list as well.\n\n- [x] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common
scenarios","sha":"45db4add3c3365c9538adf35529577462e5baf6d"}},"sourceBranch":"main","suggestedTargetBranches":["9.1","8.19"],"targetPullRequestStates":[{"branch":"9.1","label":"v9.1.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.19","label":"v8.19.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v9.2.0","branchLabelMappingKey":"^v9.2.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/227390","number":227390,"mergeCommit":{"message":"[ResponseOps]
Fixes embeddable alerts panel flaky test (#227390)\n\n## Summary\n\nI
changed the code to use API calls to create resources like rules
and\ninstall the data sample data instead of using the UI. I also fixed
a\nsmall issue with the time range selector that caused the tests to
fail.\n\nFixes: https://github.com/elastic/kibana/issues/220807.\n\n###
Checklist\n\nCheck the PR satisfies following conditions. \n\nReviewers
should verify this PR satisfies this list as well.\n\n- [x] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common
scenarios","sha":"45db4add3c3365c9538adf35529577462e5baf6d"}}]}]
BACKPORT-->

Co-authored-by: Christos Nasikas <christos.nasikas@elastic.co>
kertal pushed a commit to kertal/kibana that referenced this pull request Jul 25, 2025
## Summary

I changed the code to use API calls to create resources like rules and
install the data sample data instead of using the UI. I also fixed a
small issue with the time range selector that caused the tests to fail.

Fixes: elastic#220807.

### Checklist

Check the PR satisfies following conditions. 

Reviewers should verify this PR satisfies this list as well.

- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:version Backport to applied version labels release_note:skip Skip the PR/issue when compiling release notes v8.19.0 v9.1.0 v9.2.0

Projects

None yet

4 participants