You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat(run-tests): Handle existing namespaces and permission errors more gracefully
This _does_ change behavior.
In the past run-tests would fail if we can't create the namespace but
now we'll proceed because it might already exist and we just can't check
easily.
Ensure the specified namespace exists, creating it if necessary.
372
+
373
+
This function handles various permission scenarios:
374
+
- If the namespace already exists, it does nothing
375
+
- If it doesn't exist and we have permission, it creates it
376
+
- If we don't have permission to create/check namespaces, it logs a warning
377
+
and assumes the namespace exists or will be created externally (useful for OpenShift)
378
+
379
+
Examples of (permission) errors we handle:
380
+
- Error from server (Forbidden): namespaces is forbidden: User "developer" cannot create resource "namespaces" in API group "" at the cluster scope
381
+
- Error from server (Forbidden): namespaces "foobar123" is forbidden: User "developer" cannot get resource "namespaces" in API group "" in the namespace "foobar123"
382
+
- Error from server (AlreadyExists): namespaces "kuttl-test-finer-caiman" already exists
0 commit comments