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

[ML] Add API integration tests for start and stop datafeeds #110961

Merged
merged 2 commits into from
Sep 3, 2021

Conversation

peteharverson
Copy link
Contributor

@peteharverson peteharverson commented Sep 2, 2021

Summary

Adds API integration tests for the endpoints for starting and stopping anomaly detection datafeeds, including checks for the behavior across spaces.

  • /api/ml/jobs/force_start_datafeeds
  • /api/ml/jobs/stop_datafeeds

Part of #106113 and #63700

Checklist

Delete any items that are not applicable to this PR.

@peteharverson peteharverson added review :ml Feature:Anomaly Detection ML anomaly detection v8.0.0 release_note:skip Skip the PR/issue when compiling release notes test-api-integration auto-backport Deprecated - use backport:version if exact versions are needed v7.16.0 labels Sep 2, 2021
@peteharverson peteharverson requested a review from a team as a code owner September 2, 2021 11:06
@peteharverson peteharverson self-assigned this Sep 2, 2021
@elasticmachine
Copy link
Contributor

Pinging @elastic/ml-ui (:ml)

Comment on lines 84 to 89
afterEach(async () => {
await ml.api.closeAnomalyDetectionJob(jobIdSpace1);
await ml.api.closeAnomalyDetectionJob(jobIdSpace2);
await ml.api.cleanMlIndices();
await ml.testResources.cleanMLSavedObjects();
});
Copy link
Contributor

Choose a reason for hiding this comment

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

should it be a part of after?

x-pack/test/api_integration/apis/ml/jobs/stop_datafeeds.ts Outdated Show resolved Hide resolved
Copy link
Member

@pheyos pheyos left a comment

Choose a reason for hiding this comment

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

LGTM
Great to see these tests coming! 🎉

@pheyos
Copy link
Member

pheyos commented Sep 3, 2021

Checking test stability in a flaky test runner job ... no failure in 50 runs ✔️

Copy link
Contributor

@darnautov darnautov left a comment

Choose a reason for hiding this comment

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

LGTM

@kibanamachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

✅ unchanged

History

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

cc @peteharverson

@peteharverson peteharverson merged commit 7f6c6e4 into elastic:master Sep 3, 2021
@peteharverson peteharverson deleted the ml-datafeed-api-tests branch September 3, 2021 15:32
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Sep 3, 2021
…110961)

* [ML] Add API integration tests for start and stop datafeeds

* [ML] Edits to setup and clean-up steps following review
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Sep 3, 2021
…110961)

* [ML] Add API integration tests for start and stop datafeeds

* [ML] Edits to setup and clean-up steps following review
@kibanamachine
Copy link
Contributor

💚 Backport successful

Status Branch Result
7.15
7.x

The backport PRs will be merged automatically after passing CI.

kibanamachine added a commit that referenced this pull request Sep 3, 2021
…#111166)

* [ML] Add API integration tests for start and stop datafeeds

* [ML] Edits to setup and clean-up steps following review

Co-authored-by: Pete Harverson <peteharverson@users.noreply.github.com>
kibanamachine added a commit that referenced this pull request Sep 3, 2021
…#111167)

* [ML] Add API integration tests for start and stop datafeeds

* [ML] Edits to setup and clean-up steps following review

Co-authored-by: Pete Harverson <peteharverson@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auto-backport Deprecated - use backport:version if exact versions are needed Feature:Anomaly Detection ML anomaly detection :ml release_note:skip Skip the PR/issue when compiling release notes review test-api-integration v7.15.0 v7.16.0 v8.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants