mirror of
https://github.com/openshift/source-to-image.git
synced 2026-02-05 12:44:54 +01:00
Changed all t.Errorf & return statements into t.Fatalf
This commit is contained in:
@@ -171,24 +171,19 @@ func (i *integrationTest) exerciseCleanBuild(tag string, verifyCallback bool, im
|
||||
|
||||
b, err := sti.NewBuilder(req)
|
||||
if err != nil {
|
||||
t.Errorf("Cannot create a new builder.")
|
||||
return
|
||||
t.Fatalf("Cannot create a new builder.")
|
||||
}
|
||||
resp, err := b.Build()
|
||||
if err != nil {
|
||||
t.Errorf("An error occurred during the build: %v", err)
|
||||
return
|
||||
t.Fatalf("An error occurred during the build: %v", err)
|
||||
} else if !resp.Success {
|
||||
t.Errorf("The build failed.")
|
||||
return
|
||||
t.Fatalf("The build failed.")
|
||||
}
|
||||
if callbackInvoked != verifyCallback {
|
||||
t.Errorf("Sti build did not invoke callback")
|
||||
return
|
||||
t.Fatalf("Sti build did not invoke callback")
|
||||
}
|
||||
if callbackHasValidJson != verifyCallback {
|
||||
t.Errorf("Sti build did not invoke callback with valid json message")
|
||||
return
|
||||
t.Fatalf("Sti build did not invoke callback with valid json message")
|
||||
}
|
||||
|
||||
i.checkForImage(tag)
|
||||
@@ -223,17 +218,14 @@ func (i *integrationTest) exerciseIncrementalBuild(tag string, removePreviousIma
|
||||
|
||||
builder, err := sti.NewBuilder(req)
|
||||
if err != nil {
|
||||
t.Errorf("Unable to create builder: %v", err)
|
||||
return
|
||||
t.Fatalf("Unable to create builder: %v", err)
|
||||
}
|
||||
resp, err := builder.Build()
|
||||
if err != nil {
|
||||
t.Errorf("Unexpected error occurred during build: %v", err)
|
||||
return
|
||||
t.Fatalf("Unexpected error occurred during build: %v", err)
|
||||
}
|
||||
if !resp.Success {
|
||||
t.Errorf("STI Build failed.")
|
||||
return
|
||||
t.Fatalf("STI Build failed.")
|
||||
}
|
||||
|
||||
previousImageId := resp.ImageID
|
||||
@@ -242,17 +234,14 @@ func (i *integrationTest) exerciseIncrementalBuild(tag string, removePreviousIma
|
||||
|
||||
builder, err = sti.NewBuilder(req)
|
||||
if err != nil {
|
||||
t.Errorf("Unable to create incremental builder: %v", err)
|
||||
return
|
||||
t.Fatalf("Unable to create incremental builder: %v", err)
|
||||
}
|
||||
resp, err = builder.Build()
|
||||
if err != nil {
|
||||
t.Errorf("Unexpected error occurred during incremental build: %v", err)
|
||||
return
|
||||
t.Fatalf("Unexpected error occurred during incremental build: %v", err)
|
||||
}
|
||||
if !resp.Success {
|
||||
t.Errorf("STI incremental build failed.")
|
||||
return
|
||||
t.Fatalf("STI incremental build failed.")
|
||||
}
|
||||
|
||||
i.checkForImage(tag)
|
||||
|
||||
Reference in New Issue
Block a user