Skip to content

Commit

Permalink
Fix E2E test
Browse files Browse the repository at this point in the history
  • Loading branch information
rm3l committed Oct 16, 2024
1 parent ea34297 commit 8195a4e
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions tests/e2e/e2e_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -124,15 +124,21 @@ spec:
{
description: "reject unauthenticated requests to the metrics endpoint",
expectedLogsMatcher: SatisfyAll(
ContainSubstring("HTTP/1.1 401 Unauthorized"),
SatisfyAny(
ContainSubstring("HTTP/1.1 401 Unauthorized"),
ContainSubstring("HTTP/2 401"),
),
Not(ContainSubstring(`workqueue_work_duration_seconds_count`)),
),
},
{
description: "reject authenticated requests to the metrics endpoint with a service account token lacking RBAC permission",
withBearerAuth: true,
expectedLogsMatcher: SatisfyAll(
ContainSubstring("HTTP/1.1 403 Forbidden"),
SatisfyAny(
ContainSubstring("HTTP/1.1 403 Forbidden"),
ContainSubstring("HTTP/2 403"),
),
Not(ContainSubstring(`workqueue_work_duration_seconds_count`)),
),
},
Expand Down

0 comments on commit 8195a4e

Please sign in to comment.