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

Fix TestUserWorkloadMonitoringAlerting for Prometheus Operator v0.52 #1479

Conversation

raptorsun
Copy link
Contributor

@raptorsun raptorsun commented Nov 15, 2021

Prometheus Operator version 0.52 has a new feature to append a postfix to the rule file name to avoid name collision. This breaks the E2E test TestUserWorkloadMonitoringAlerting which assumes rule file without this postfix.

This PR update that test so it can pass after upgrading Prometheus Operator to version 0.52.

rule file name before 0.52: /etc/prometheus/rules/prometheus-user-workload-rulefiles-0/user-workload-test-prometheus-example-rule-leaf.yaml
rule file name after 0.52: /etc/prometheus/rules/prometheus-user-workload-rulefiles-0/user-workload-test-prometheus-example-rule-leaf-f4c6359f-9510-4c1d-9b44-5aa014b3aacd.yaml

  • I added CHANGELOG entry for this change.
  • No user facing changes, so no entry in CHANGELOG was needed.

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Nov 15, 2021
@raptorsun
Copy link
Contributor Author

/retest-required

@raptorsun
Copy link
Contributor Author

/test e2e-aws-single-node

@fpetkovski
Copy link
Contributor

That assertion is testing an implementation detail of Prometheus Operator, there's no guarantee that the file name won't change in the future. Do we still need to have this test?

@raptorsun
Copy link
Contributor Author

raptorsun commented Nov 16, 2021

That assertion is testing an implementation detail of Prometheus Operator, there's no guarantee that the file name won't change in the future. Do we still need to have this test?

I think this test is for verifying the rule files are created correctly.
Maybe we should ignore file names and check only name + namespace + rule type?
What do you think? @simonpasquier @s-urbaniak 🙋‍♂️

@simonpasquier
Copy link
Contributor

I agree with @fpetkovski: the test shouldn't check the filename.

@raptorsun raptorsun force-pushed the bugfix/unit-test-prometheus-operator branch from 0b1fbeb to de3680b Compare November 16, 2021 09:54
@raptorsun
Copy link
Contributor Author

Test updated, no checks on file name now :)

@raptorsun
Copy link
Contributor Author

/test e2e-aws-single-node

Copy link
Contributor

@simonpasquier simonpasquier left a comment

Choose a reason for hiding this comment

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

/lgtm

@simonpasquier
Copy link
Contributor

/label qe-approved
/label docs-approved
/label px-approved

this is only updating the e2e tests, no functional change.

@openshift-ci openshift-ci bot added qe-approved Signifies that QE has signed off on this PR docs-approved Signifies that Docs has signed off on this PR px-approved Signifies that Product Support has signed off on this PR labels Nov 17, 2021
@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Nov 17, 2021
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Nov 17, 2021

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: raptorsun, simonpasquier

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:
  • OWNERS [raptorsun,simonpasquier]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-bot
Copy link
Contributor

/retest-required

Please review the full test history for this PR and help us cut down flakes.

8 similar comments
@openshift-bot
Copy link
Contributor

/retest-required

Please review the full test history for this PR and help us cut down flakes.

@openshift-bot
Copy link
Contributor

/retest-required

Please review the full test history for this PR and help us cut down flakes.

@openshift-bot
Copy link
Contributor

/retest-required

Please review the full test history for this PR and help us cut down flakes.

@openshift-bot
Copy link
Contributor

/retest-required

Please review the full test history for this PR and help us cut down flakes.

@openshift-bot
Copy link
Contributor

/retest-required

Please review the full test history for this PR and help us cut down flakes.

@openshift-bot
Copy link
Contributor

/retest-required

Please review the full test history for this PR and help us cut down flakes.

@openshift-bot
Copy link
Contributor

/retest-required

Please review the full test history for this PR and help us cut down flakes.

@openshift-bot
Copy link
Contributor

/retest-required

Please review the full test history for this PR and help us cut down flakes.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Nov 17, 2021

@raptorsun: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/e2e-aws-single-node de3680b link false /test e2e-aws-single-node

Full PR test history. Your PR dashboard.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@simonpasquier
Copy link
Contributor

/skip
/test e2e-agnostic-operator

@openshift-merge-robot openshift-merge-robot merged commit 6e1a58e into openshift:master Nov 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. docs-approved Signifies that Docs has signed off on this PR lgtm Indicates that a PR is ready to be merged. px-approved Signifies that Product Support has signed off on this PR qe-approved Signifies that QE has signed off on this PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants