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

[Alerts] Fixing skipped unit tests for metric threshold rule #162189

Merged

Conversation

simianhacker
Copy link
Member

Summary

This PR fixes #155534 by ensuring result for the group by is set before adding it to the evaluation results. I also applied the fix to the new Observability Threshold Rule since we are using it as a starting point for the new combined rule.

@simianhacker simianhacker added release_note:fix Team: Actionable Observability - DEPRECATED For Observability Alerting and SLOs use "Team:obs-ux-management", for AIops "Team:obs-knowledge" v8.10.0 labels Jul 18, 2023
@simianhacker simianhacker marked this pull request as ready for review July 18, 2023 20:30
@simianhacker simianhacker requested a review from a team as a code owner July 18, 2023 20:30
@elasticmachine
Copy link
Contributor

Pinging @elastic/actionable-observability (Team: Actionable Observability)

@apmmachine
Copy link
Contributor

🤖 GitHub comments

Expand to view the GitHub comments

Just comment with:

  • /oblt-deploy : Deploy a Kibana instance using the Observability test environments.
  • run elasticsearch-ci/docs : Re-trigger the docs validation. (use unformatted text in the comment!)

Copy link
Member

@maryam-saeidi maryam-saeidi left a comment

Choose a reason for hiding this comment

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

Thanks, Chris, for the fix! ❤️

Just added one question.

@@ -1394,7 +1394,7 @@ describe.skip('The metric threshold alert type', () => {
await execute(true);
const recentAction = mostRecentAction(instanceID);
expect(recentAction.action).toEqual({
alertDetailsUrl: 'http://localhost:5601/app/observability/alerts/mock-alert-uuid',
alertDetailsUrl: '',
Copy link
Member

@maryam-saeidi maryam-saeidi Jul 19, 2023

Choose a reason for hiding this comment

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

Can we also remove the skip from this test? If not, I will create a separate ticket for it.

Copy link
Member Author

Choose a reason for hiding this comment

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

Whoops... I missed that.

Copy link
Member Author

Choose a reason for hiding this comment

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

That test needs a lot more work before we are ready to remove the skip statement. It's failing beyond just the single test this PR is fixing.

Copy link
Member

@maryam-saeidi maryam-saeidi Jul 20, 2023

Choose a reason for hiding this comment

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

I thought so, here is the ticket for it: #162299

@simianhacker simianhacker enabled auto-merge (squash) July 19, 2023 16:57
@simianhacker simianhacker merged commit 8303ea9 into elastic:main Jul 19, 2023
@kibana-ci
Copy link
Collaborator

💚 Build Succeeded

Metrics [docs]

✅ unchanged

History

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

@kibanamachine kibanamachine added the backport:skip This commit does not require backporting label Jul 19, 2023
ThomThomson pushed a commit to ThomThomson/kibana that referenced this pull request Aug 1, 2023
…#162189)

## Summary

This PR fixes elastic#155534 by ensuring result for the group by is set before
adding it to the evaluation results. I also applied the fix to the new
Observability Threshold Rule since we are using it as a starting point
for the new combined rule.
@simianhacker simianhacker deleted the issue-155534-fixing-test-for-no-data branch April 17, 2024 15:38
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 release_note:fix Team: Actionable Observability - DEPRECATED For Observability Alerting and SLOs use "Team:obs-ux-management", for AIops "Team:obs-knowledge" v8.10.0
Projects
None yet
6 participants