-
Notifications
You must be signed in to change notification settings - Fork 263
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
e2e test fails if there are resouces created by the previous test #576
Comments
AFAIR we create all resources in a temporary namespace and then just remove that namespace after the test. So a Or are you talking about cluster-wide resources ? |
I try delete ns. But |
That's correct, though there are multiple test namespaces kne2etests[0-9], and the SA, ClusterRole and ClusterRoleBindings are introduced recently. We do need tear down functionality. |
correct, ClusterRole and ClusterRoleBindings are cluster-wide resources which need to be cleaned up seperately. I wonder, whether those cluster-wide resources (if different) work nicely with parallel running tests ? Or ar their names also randomized (so that they don't interfer which each other) ? An idea: We could use the suffix of the namespace under test for the cluster role names and then just delete all clusterroles with those prefix. This would be generic enough and doesn't need constant maintenance. |
I am also seeing this issue consistently as well with The |
The danger is if there is a running e2e, which we can claim is not supported (e.g., running e2e multiple times at once). Thoughts? -- It must fail . If a test is running, another test will meet |
Completes knative#576 - For ApiServer source: ClusteRole and ClusterRoleBinding name(s) are now test-namespace specific. They are cleared in test's tearDown method. - Use constant prefix as: clusterRolePrefix = "apiserver-role-" clusterRoleBindingPrefix = "apiserver-binding-" - Use constant ServiceAccountName as: testServiceAccount = "apiserver-sa" - Rename methods and cleanup.
Completes knative#576 - For ApiServer source: ClusteRole and ClusterRoleBinding name(s) are now test-namespace specific. They are cleared in test's tearDown method. - Use constant prefix as: clusterRolePrefix = "apiserver-role-" clusterRoleBindingPrefix = "apiserver-binding-" - Use constant ServiceAccountName as: testServiceAccount = "apiserver-sa" - Rename methods and cleanup.
* chore(e2e): Namespace specific k8s resources for tests Completes #576 - For ApiServer source: ClusteRole and ClusterRoleBinding name(s) are now test-namespace specific. They are cleared in test's tearDown method. - Use constant prefix as: clusterRolePrefix = "apiserver-role-" clusterRoleBindingPrefix = "apiserver-binding-" - Use constant ServiceAccountName as: testServiceAccount = "apiserver-sa" - Rename methods and cleanup. * Use correct format specifier for error as %v instead of %s
Describe the feature:
The e2e test may fail in sometime, for example failing download docker image. When start test again, it will fail for some existed resource. In this situation, I have to clear resource manually.
Is there a command or shell to clear all resource the test has created?
The text was updated successfully, but these errors were encountered: