Files
odo/pkg/testingutil/containers.go
Mrinal Das d160b0097f Adds list command of storage for devfile v2 (#3788)
* Adds list command of storage for devfile v2

* Fixes import names in cli/storage/list.go

* Fixes display of componentName in list output. It also converts some functions to private and adds project flag while creating components in the storage script.

* Uses default storage size from the adapter

* Changes default storage size in integration test
2020-08-31 07:46:24 -04:00

18 lines
580 B
Go

package testingutil
import corev1 "k8s.io/api/core/v1"
// CreateFakeContainer creates a container with the given containerName
func CreateFakeContainer(containerName string) corev1.Container {
return corev1.Container{
Name: containerName,
}
}
// CreateFakeContainerWithVolumeMounts creates a container with the given containerName and volumeMounts
func CreateFakeContainerWithVolumeMounts(containerName string, volumeMounts []corev1.VolumeMount) corev1.Container {
container := CreateFakeContainer(containerName)
container.VolumeMounts = volumeMounts
return container
}