Skip to content

Commit

Permalink
oops
Browse files Browse the repository at this point in the history
  • Loading branch information
briandealwis committed Sep 28, 2020
1 parent 3042548 commit a7e67e1
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 6 deletions.
4 changes: 3 additions & 1 deletion pkg/skaffold/debug/debug_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -592,7 +592,9 @@ status: {}`,
return imageConfiguration{}, nil
}

result, err := applyDebuggingTransforms(manifest.Load(bytes.NewReader([]byte(test.in))), retriever, "HELPERS")
l, err := manifest.Load(bytes.NewReader([]byte(test.in)))
t.CheckError(false, err)
result, err := applyDebuggingTransforms(l, retriever, "HELPERS")

t.CheckErrorAndDeepEqual(test.shouldErr, err, test.out, result.String())
})
Expand Down
12 changes: 7 additions & 5 deletions pkg/skaffold/kubernetes/manifest/manifests.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,14 +36,16 @@ func Load(in io.Reader) (ManifestList, error) {
var docs [][]byte
for {
doc, err := r.Read()
if err == io.EOF {
break
} else {
switch {
case err == io.EOF:
return ManifestList(docs), nil
case err != nil:
return nil, err
default:
docs = append(docs, doc)
}
docs = append(docs, doc)
}
return ManifestList(docs), nil

}

func (l *ManifestList) String() string {
Expand Down

0 comments on commit a7e67e1

Please sign in to comment.