remove portsforobject from factory
This commit is contained in:
@@ -22,6 +22,7 @@ import (
|
||||
"k8s.io/api/core/v1"
|
||||
"k8s.io/apimachinery/pkg/api/meta"
|
||||
"k8s.io/apimachinery/pkg/runtime"
|
||||
"k8s.io/apimachinery/pkg/runtime/schema"
|
||||
"k8s.io/client-go/rest"
|
||||
api "k8s.io/kubernetes/pkg/apis/core"
|
||||
"k8s.io/kubernetes/pkg/kubectl"
|
||||
@@ -58,3 +59,15 @@ type UpdatePodSpecForObjectFunc func(obj runtime.Object, fn func(*v1.PodSpec) er
|
||||
|
||||
// UpdatePodSpecForObjectFn gives a way to easily override the function for unit testing if needed
|
||||
var UpdatePodSpecForObjectFn UpdatePodSpecForObjectFunc = updatePodSpecForObject
|
||||
|
||||
// PortsForObjectFunc returns the ports associated with the provided object
|
||||
type PortsForObjectFunc func(object runtime.Object) ([]string, error)
|
||||
|
||||
// PortsForObjectFn gives a way to easily override the function for unit testing if needed
|
||||
var PortsForObjectFn PortsForObjectFunc = portsForObject
|
||||
|
||||
// CanBeAutoscaledFunc checks whether the kind of resources could be autoscaled
|
||||
type CanBeAutoscaledFunc func(kind schema.GroupKind) error
|
||||
|
||||
// CanBeAutoscaledFn gives a way to easily override the function for unit testing if needed
|
||||
var CanBeAutoscaledFn CanBeAutoscaledFunc = canBeAutoscaled
|
||||
|
Reference in New Issue
Block a user