-
Notifications
You must be signed in to change notification settings - Fork 71
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 for empty payload consumer commit #834
Conversation
9211c5e
to
2486768
Compare
2486768
to
d00ab8a
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks fine except for the trail that I feel it’s useless. It is?
topic_name = new_topic(admin_client) | ||
offsets_path = f"/consumers/{group_name}/instances/{instance_id}/offsets{trail}" | ||
assign_path = f"/consumers/{group_name}/instances/{instance_id}/assignments{trail}" | ||
consume_path = f"/consumers/{group_name}/instances/{instance_id}/records{trail}?timeout=5000" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why the optional trailing?
@@ -251,6 +251,80 @@ async def test_offsets(rest_async_client, admin_client, trail): | |||
assert "partition" in data and data["partition"] == 0, f"Unexpected partition {data}" | |||
|
|||
|
|||
@pytest.mark.parametrize("trail", ["", "/"]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I cannot see the value of that parameter
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've followed the pattern of the other tests here, which all have it. I sort of understand why that is there, with some frameworks this can go wrong fairly easy :(
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess what's odd is that we support both, but since we do, I guess it makes sense to test it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See you spaceboy 🔫
About this change - What it does
Following up on #833, adding tests around the fix that was hastily implemented there.