17 Commits

Author SHA1 Message Date
Kubernetes Prow Robot
79d1cf301e Merge pull request #131409 from bertinatto/fix-authz-test
e2e: set appropriate groups in SAR of kubelet authz test
2025-05-08 14:39:15 -07:00
Maysa Macedo
b1bb9a5885 Kubelet: Randomize ClusterRole name in e2e
It's possible that a conflict will happen when
attempting to create a `ClusterRole` resource
without a randomized name given that is a cluster
scoped object and another object with same name
might exist. This commit fixes this issue by ensuring
the name of the `ClusterRole` is randomized. Additionally,
it adds clean up for the clusterRole and clusterRoleBinding.
2025-05-06 14:30:10 -03:00
Fabio Bertinatto
e36a168a63 test/e2e/node/kubelet_authz.go: fix SAR to include service account groups
This sets the appropriate groups (system:authenticated, system:serviceaccounts,
system:serviceaccounts:<ns>) in the SAR used in WaitForAuthzUpdate to accurately
simulate the service account’s identity.
2025-05-05 10:37:42 -03:00
Vinayak Goyal
3a780a1c1b KEP-2862: Graduate to BETA. 2025-01-24 21:36:00 +00:00
yintong.huang
2db1b321e0 drop deprecated PollWithContext and adopt PollUntilContextTimeout instead
Signed-off-by: yintong.huang <yintong.huang@daocloud.io>
2024-06-21 19:23:31 +08:00
Ed Bartosh
ff9ebfa90d e2e framework: control k/k/pkg imports
Modified import restrictions for the e2e framework submodules
to enable control of the k/k/pkg imports.
2023-04-17 00:17:16 +03:00
Patrick Ohly
3e760310b2 e2e: revise import restrictions
- test/e2e/framework/*.go should have very minimal dependencies.
  We can enforce that via import-boss.

- What each test/e2e/framework/* sub-package uses is less relevant,
  although ideally it also should be as minimal as possible in each case.

Enforcing this via import-boss ensures that new dependencies get flagged as
problem and thus will get additional scrutiny. It might be okay to add them,
but it needs to be considered.
2023-02-12 14:56:45 +01:00
Patrick Ohly
2f6c4f5eab e2e: use Ginkgo context
All code must use the context from Ginkgo when doing API calls or polling for a
change, otherwise the code would not return immediately when the test gets
aborted.
2022-12-16 20:14:04 +01:00
Patrick Ohly
2d21acb1be e2e framework: eliminate redundant framework/[log|ginkgowrapper]
These sub packages were created by mistake. Logging and failure handling are
core features and must be implemented in the framework package.
2022-10-06 08:16:47 +02:00
Niu Lechuan
12dcd2f84d Remove usage of github.com/pkg/errors
Signed-off-by: Niu Lechuan <lechuan.niu@daocloud.io>
2021-06-23 17:46:23 +08:00
Benjamin Elder
56e092e382 hack/update-bazel.sh 2021-02-28 15:17:29 -08:00
Mike Danese
25651408ae generated: run refactor 2020-02-08 12:30:21 -05:00
Mike Danese
3aa59f7f30 generated: run refactor 2020-02-07 18:16:47 -08:00
tanjunchen
587dbc2fed remove TODO in test/e2e/framework/auth/helpers 2019-12-31 11:20:31 +08:00
Jordan Liggitt
8229af31d2 Move test/e2e use to v1 APIs 2019-06-03 14:46:08 -04:00
John Schnake
3853a0ecd9 GKE also requires SAR endpoints
There was a specific error flow that was commented as only applying
to GKE. This was never tested specifically for GKE (only commented
as such) but that seems to be out of date and can be removed. If
the SAR endpoint does not exist it should be considered an error.
2019-05-02 10:20:49 -05:00
John Schnake
028df0451d Refactor of e2e/framework/authorizer_util.go
- moves these helper functions into e2e/framework/auth
 - removes logging from helper functions
 - in some cases explicitly returns errors that were implicitly
ignored/logged. In the situations where they should be ignored,
we explicitly check that the condition is met before ignoring it.
 - fixes references of these methods to use the right package and
return values
2019-04-17 16:39:37 -05:00