mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-29 06:06:03 +00:00
Allow custom namespace creation in e2e framework
This commit is contained in:
@@ -225,6 +225,10 @@ func (f *Framework) afterEach() {
|
||||
}
|
||||
|
||||
func (f *Framework) CreateNamespace(baseName string, labels map[string]string) (*api.Namespace, error) {
|
||||
createTestingNS := testContext.CreateTestingNS
|
||||
if createTestingNS == nil {
|
||||
createTestingNS = CreateTestingNS
|
||||
}
|
||||
ns, err := createTestingNS(baseName, f.Client, labels)
|
||||
if err == nil {
|
||||
f.namespacesToDelete = append(f.namespacesToDelete, ns)
|
||||
|
Reference in New Issue
Block a user