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

Add tests to TestMatchers #3357

Merged

Conversation

grobinson-grafana
Copy link
Contributor

This commit adds a number of tests to TestMatchers that asserts some of the more nuanced behavior when parsing label matchers.

This commit adds a number of tests to TestMatchers that asserts
some of the more nuanced behavior when parsing label matchers.

Signed-off-by: George Robinson <[email protected]>
Signed-off-by: George Robinson <[email protected]>
@grobinson-grafana grobinson-grafana force-pushed the grobinson/add-tests-for-matchers branch from d052d40 to 101f7bb Compare May 12, 2023 09:05
Copy link
Member

@gotjosh gotjosh left a comment

Choose a reason for hiding this comment

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

Nice work! LGTM but please see my comments.

err: `bad matcher format: {foo=`,
},
{
// This looks like a bug which should be fixed
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
// This looks like a bug which should be fixed

Copy link
Member

Choose a reason for hiding this comment

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

I suggest we don't leave these tasks as comments in the code and instead either: a) open individual PRs to fix them or b) keep them in your task list of things to do so that we can discuss them individually.

}(),
},
{
// This also looks like a bug which should be fixed
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
// This also looks like a bug which should be fixed

Copy link
Member

@gotjosh gotjosh left a comment

Choose a reason for hiding this comment

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

Nice work! LGTM but please see my comments.

Signed-off-by: George Robinson <[email protected]>
@gotjosh gotjosh merged commit f67d03f into prometheus:main May 12, 2023
@gotjosh
Copy link
Member

gotjosh commented May 12, 2023

Thank you very much for this contribution.

qinxx108 pushed a commit to qinxx108/alertmanager that referenced this pull request Jun 6, 2023
* Add tests to TestMatchers

This commit adds a number of tests to TestMatchers that asserts
some of the more nuanced behavior when parsing label matchers.

Signed-off-by: George Robinson <[email protected]>

---------

Signed-off-by: George Robinson <[email protected]>
Signed-off-by: Yijie Qin <[email protected]>
qinxx108 pushed a commit to qinxx108/alertmanager that referenced this pull request Jul 5, 2023
* Add tests to TestMatchers

This commit adds a number of tests to TestMatchers that asserts
some of the more nuanced behavior when parsing label matchers.

Signed-off-by: George Robinson <[email protected]>

---------

Signed-off-by: George Robinson <[email protected]>
Signed-off-by: Yijie Qin <[email protected]>
qinxx108 pushed a commit to qinxx108/alertmanager that referenced this pull request Jul 6, 2023
* Add tests to TestMatchers

This commit adds a number of tests to TestMatchers that asserts
some of the more nuanced behavior when parsing label matchers.

Signed-off-by: George Robinson <[email protected]>

---------

Signed-off-by: George Robinson <[email protected]>
Signed-off-by: Yijie Qin <[email protected]>
qinxx108 pushed a commit to qinxx108/alertmanager that referenced this pull request Jul 7, 2023
* Add tests to TestMatchers

This commit adds a number of tests to TestMatchers that asserts
some of the more nuanced behavior when parsing label matchers.

Signed-off-by: George Robinson <[email protected]>

---------

Signed-off-by: George Robinson <[email protected]>
Signed-off-by: Yijie Qin <[email protected]>
gotjosh pushed a commit that referenced this pull request Aug 7, 2023
* Add tests to TestMatchers

This commit adds a number of tests to TestMatchers that asserts
some of the more nuanced behavior when parsing label matchers.

Signed-off-by: George Robinson <[email protected]>

---------

Signed-off-by: George Robinson <[email protected]>
radek-ryckowski pushed a commit to goldmansachs/alertmanager that referenced this pull request Nov 6, 2023
* Add tests to TestMatchers

This commit adds a number of tests to TestMatchers that asserts
some of the more nuanced behavior when parsing label matchers.

Signed-off-by: George Robinson <[email protected]>

---------

Signed-off-by: George Robinson <[email protected]>
qinxx108 pushed a commit to amazon-contributing/alertmanager that referenced this pull request Mar 28, 2024
* Add tests to TestMatchers

This commit adds a number of tests to TestMatchers that asserts
some of the more nuanced behavior when parsing label matchers.

Signed-off-by: George Robinson <[email protected]>

---------

Signed-off-by: George Robinson <[email protected]>
@grobinson-grafana grobinson-grafana deleted the grobinson/add-tests-for-matchers branch April 16, 2024 14:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants