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

Failing test: X-Pack Alerting API Integration Tests.x-pack/test/alerting_api_integration/security_and_spaces/group1/tests/alerting/find·ts - alerting api integration security and spaces enabled Alerts - Group 1 alerts find public superuser at space1 should handle find alert request appropriately #148660

Closed
kibanamachine opened this issue Jan 10, 2023 · 5 comments · Fixed by #152455
Assignees
Labels
failed-test A test failure on a tracked branch, potentially flaky-test Team:ResponseOps Label for the ResponseOps team (formerly the Cases and Alerting teams)

Comments

@kibanamachine
Copy link
Contributor

kibanamachine commented Jan 10, 2023

A test failed on a tracked branch

Error: expected { id: '433e96c0-9106-11ed-b7d3-9f56d3aed9df',
  enabled: true,
  name: 'abc',
  tags: [ 'foo' ],
  consumer: 'alertsFixture',
  throttle: '1m',
  running: true,
  schedule: { interval: '1m' },
  params: {},
  rule_type_id: 'test.noop',
  created_by: 'elastic',
  updated_by: 'elastic',
  created_at: '2023-01-10T16:46:01.163Z',
  updated_at: '2023-01-10T16:46:01.163Z',
  api_key_owner: 'elastic',
  notify_when: 'onThrottleInterval',
  mute_all: false,
  muted_alert_ids: [],
  scheduled_task_id: '433e96c0-9106-11ed-b7d3-9f56d3aed9df',
  execution_status: 
   { status: 'pending',
     last_execution_date: '2023-01-10T16:46:01.163Z' },
  actions: [] } to sort of equal { id: '433e96c0-9106-11ed-b7d3-9f56d3aed9df',
  name: 'abc',
  tags: [ 'foo' ],
  rule_type_id: 'test.noop',
  running: false,
  consumer: 'alertsFixture',
  schedule: { interval: '1m' },
  enabled: true,
  actions: [],
  params: {},
  created_by: 'elastic',
  scheduled_task_id: '433e96c0-9106-11ed-b7d3-9f56d3aed9df',
  created_at: '2023-01-10T16:46:01.163Z',
  updated_at: '2023-01-10T16:46:01.163Z',
  throttle: '1m',
  notify_when: 'onThrottleInterval',
  updated_by: 'elastic',
  api_key_owner: 'elastic',
  mute_all: false,
  muted_alert_ids: [],
  execution_status: 
   { status: 'pending',
     last_execution_date: '2023-01-10T16:46:01.163Z' } }
    at Assertion.assert (expect.js:100:11)
    at Assertion.eql (expect.js:244:8)
    at Context.<anonymous> (find.ts:66:32)
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
    at Object.apply (wrap_function.js:73:16) {
  actual: '{\n' +
    '  "actions": []\n' +
    '  "api_key_owner": "elastic"\n' +
    '  "consumer": "alertsFixture"\n' +
    '  "created_at": "2023-01-10T16:46:01.163Z"\n' +
    '  "created_by": "elastic"\n' +
    '  "enabled": true\n' +
    '  "execution_status": {\n' +
    '    "last_execution_date": "2023-01-10T16:46:01.163Z"\n' +
    '    "status": "pending"\n' +
    '  }\n' +
    '  "id": "433e96c0-9106-11ed-b7d3-9f56d3aed9df"\n' +
    '  "mute_all": false\n' +
    '  "muted_alert_ids": []\n' +
    '  "name": "abc"\n' +
    '  "notify_when": "onThrottleInterval"\n' +
    '  "params": {}\n' +
    '  "rule_type_id": "test.noop"\n' +
    '  "running": true\n' +
    '  "schedule": {\n' +
    '    "interval": "1m"\n' +
    '  }\n' +
    '  "scheduled_task_id": "433e96c0-9106-11ed-b7d3-9f56d3aed9df"\n' +
    '  "tags": [\n' +
    '    "foo"\n' +
    '  ]\n' +
    '  "throttle": "1m"\n' +
    '  "updated_at": "2023-01-10T16:46:01.163Z"\n' +
    '  "updated_by": "elastic"\n' +
    '}',
  expected: '{\n' +
    '  "actions": []\n' +
    '  "api_key_owner": "elastic"\n' +
    '  "consumer": "alertsFixture"\n' +
    '  "created_at": "2023-01-10T16:46:01.163Z"\n' +
    '  "created_by": "elastic"\n' +
    '  "enabled": true\n' +
    '  "execution_status": {\n' +
    '    "last_execution_date": "2023-01-10T16:46:01.163Z"\n' +
    '    "status": "pending"\n' +
    '  }\n' +
    '  "id": "433e96c0-9106-11ed-b7d3-9f56d3aed9df"\n' +
    '  "mute_all": false\n' +
    '  "muted_alert_ids": []\n' +
    '  "name": "abc"\n' +
    '  "notify_when": "onThrottleInterval"\n' +
    '  "params": {}\n' +
    '  "rule_type_id": "test.noop"\n' +
    '  "running": false\n' +
    '  "schedule": {\n' +
    '    "interval": "1m"\n' +
    '  }\n' +
    '  "scheduled_task_id": "433e96c0-9106-11ed-b7d3-9f56d3aed9df"\n' +
    '  "tags": [\n' +
    '    "foo"\n' +
    '  ]\n' +
    '  "throttle": "1m"\n' +
    '  "updated_at": "2023-01-10T16:46:01.163Z"\n' +
    '  "updated_by": "elastic"\n' +
    '}',
  showDiff: true
}

First failure: CI Build - main

@kibanamachine kibanamachine added the failed-test A test failure on a tracked branch, potentially flaky-test label Jan 10, 2023
@botelastic botelastic bot added the needs-team Issues missing a team label label Jan 10, 2023
@kibanamachine kibanamachine added the Team:ResponseOps Label for the ResponseOps team (formerly the Cases and Alerting teams) label Jan 10, 2023
@elasticmachine
Copy link
Contributor

Pinging @elastic/response-ops (Team:ResponseOps)

@botelastic botelastic bot removed the needs-team Issues missing a team label label Jan 10, 2023
@kibanamachine
Copy link
Contributor Author

New failure: CI Build - main

mistic added a commit that referenced this issue Jan 10, 2023
@mistic
Copy link
Member

mistic commented Jan 10, 2023

Skipped.

main: b7ff354

jennypavlova pushed a commit to jennypavlova/kibana that referenced this issue Jan 13, 2023
@XavierM XavierM self-assigned this Jan 26, 2023
@XavierM XavierM moved this from Awaiting Triage to Todo in AppEx: ResponseOps - Rules & Alerts Management Jan 26, 2023
@XavierM XavierM moved this from Todo to Up for grabs in AppEx: ResponseOps - Rules & Alerts Management Feb 22, 2023
XavierM added a commit that referenced this issue Mar 1, 2023
## Summary

Fix #148660


### Checklist

- [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
kibanamachine pushed a commit to kibanamachine/kibana that referenced this issue Mar 1, 2023
## Summary

Fix elastic#148660

### Checklist

- [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 5612da9)
kibanamachine referenced this issue Mar 1, 2023
…52466)

# Backport

This will backport the following commits from `main` to `8.7`:
- [[RAM] Fix flaky test on rule find api integration
(#152455)](#152455)

<!--- Backport version: 8.9.7 -->

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

<!--BACKPORT [{"author":{"name":"Xavier
Mouligneau","email":"xavier.mouligneau@elastic.co"},"sourceCommit":{"committedDate":"2023-03-01T15:29:17Z","message":"[RAM]
Fix flaky test on rule find api integration (#152455)\n\n##
Summary\r\n\r\nFix
https://github.com/elastic/kibana/issues/148660\r\n\r\n\r\n###
Checklist\r\n\r\n- [x] [Unit or
functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere
updated or added to match the most common
scenarios","sha":"5612da95fe5052af1a51ee7ba537ae355124c1ad","branchLabelMapping":{"^v8.8.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","Team:ResponseOps","v8.7.0","v8.8.0"],"number":152455,"url":"https://github.com/elastic/kibana/pull/152455","mergeCommit":{"message":"[RAM]
Fix flaky test on rule find api integration (#152455)\n\n##
Summary\r\n\r\nFix
https://github.com/elastic/kibana/issues/148660\r\n\r\n\r\n###
Checklist\r\n\r\n- [x] [Unit or
functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere
updated or added to match the most common
scenarios","sha":"5612da95fe5052af1a51ee7ba537ae355124c1ad"}},"sourceBranch":"main","suggestedTargetBranches":["8.7"],"targetPullRequestStates":[{"branch":"8.7","label":"v8.7.0","labelRegex":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v8.8.0","labelRegex":"^v8.8.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/152455","number":152455,"mergeCommit":{"message":"[RAM]
Fix flaky test on rule find api integration (#152455)\n\n##
Summary\r\n\r\nFix
https://github.com/elastic/kibana/issues/148660\r\n\r\n\r\n###
Checklist\r\n\r\n- [x] [Unit or
functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere
updated or added to match the most common
scenarios","sha":"5612da95fe5052af1a51ee7ba537ae355124c1ad"}}]}]
BACKPORT-->

Co-authored-by: Xavier Mouligneau <xavier.mouligneau@elastic.co>
bmorelli25 pushed a commit to bmorelli25/kibana that referenced this issue Mar 10, 2023
## Summary

Fix elastic#148660


### Checklist

- [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
@mikecote
Copy link
Contributor

mikecote commented Jul 24, 2023

Re-opening as the tests are still skipped.

@XavierM
Copy link
Contributor

XavierM commented Aug 22, 2023

@guskovaue you also need to do this one -> x-pack/test/alerting_api_integration/security_and_spaces/group1/tests/alerting/find_with_post.ts

guskovaue added a commit that referenced this issue Aug 23, 2023
Solve this issue: #148660

Fix flaky 'find with post' rule endpoint supertests.

Tested using this tool:
https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/2963

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
@guskovaue guskovaue moved this from In Progress to In Review in AppEx: ResponseOps - Rules & Alerts Management Aug 24, 2023
@XavierM XavierM closed this as completed Aug 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
failed-test A test failure on a tracked branch, potentially flaky-test Team:ResponseOps Label for the ResponseOps team (formerly the Cases and Alerting teams)
Projects
No open projects
8 participants