@@ -81,12 +81,6 @@ type FakeVersion struct {
|
||||
Version string
|
||||
}
|
||||
|
||||
func snapshot(imageList []kubecontainer.Image) []kubecontainer.Image {
|
||||
result := make([]kubecontainer.Image, len(imageList))
|
||||
copy(result, imageList)
|
||||
return result
|
||||
}
|
||||
|
||||
func (fv *FakeVersion) String() string {
|
||||
return fv.Version
|
||||
}
|
||||
@@ -371,6 +365,12 @@ func (f *FakeRuntime) ListImages(_ context.Context) ([]kubecontainer.Image, erro
|
||||
return snapshot(f.ImageList), f.Err
|
||||
}
|
||||
|
||||
func snapshot(imageList []kubecontainer.Image) []kubecontainer.Image {
|
||||
result := make([]kubecontainer.Image, len(imageList))
|
||||
copy(result, imageList)
|
||||
return result
|
||||
}
|
||||
|
||||
func (f *FakeRuntime) RemoveImage(_ context.Context, image kubecontainer.ImageSpec) error {
|
||||
f.Lock()
|
||||
defer f.Unlock()
|
||||
|
Reference in New Issue
Block a user