Unwrap ResourceList with a functionConfig but no items

This commit is contained in:
Katrina Verey
2021-01-12 16:13:40 -08:00
parent ea5d08bac5
commit bdbfb28139
2 changed files with 24 additions and 1 deletions

View File

@@ -94,6 +94,29 @@ spec:
elems:
- a
- b
- c`,
wrappingAPIVersion: ResourceListAPIVersion,
wrappingAPIKind: ResourceListKind,
},
//
//
//
{
name: "wrapped_resource_list_function_config_without_items",
input: `apiVersion: config.kubernetes.io/v1alpha1
kind: ResourceList
functionConfig:
foo: bar
elems:
- a
- b
- c
`,
expectedItems: []string{},
expectedFunctionConfig: `foo: bar
elems:
- a
- b
- c`,
wrappingAPIVersion: ResourceListAPIVersion,
wrappingAPIKind: ResourceListKind,