Skip to content

Commit

Permalink
return code check switch
Browse files Browse the repository at this point in the history
Signed-off-by: Dhruv-J <[email protected]>
  • Loading branch information
Dhruv-J committed Jul 19, 2023
1 parent 0ead4b7 commit 0c3393f
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions test/e2e/framework.go
Original file line number Diff line number Diff line change
Expand Up @@ -1625,10 +1625,10 @@ func (data *TestData) copyNodeFiles(nodeName, fileName, covDir, covPrefix string
cmd := fmt.Sprintf("cat %s", fileName)
fmt.Println("_______________ copyNodeFiles: cat command set")
rc, stdout, _, err := data.RunCommandOnNode(nodeName, cmd)
if err != nil || rc != 0 {
return fmt.Errorf("error in copyNodeFiles: %v \nreturn code: %d", err, rc)
if err != nil {
return fmt.Errorf("error in copyNodeFiles: %v", err)
}
if stdout == "" {
if rc != 0 || stdout == "" {
fmt.Printf("_______________ copyNodeFiles: cat command stdout empty\n")
os.Remove(w.Name())
return nil
Expand Down

0 comments on commit 0c3393f

Please sign in to comment.