mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2024-12-24 10:07:21 +02:00
fixed unit test
This commit is contained in:
parent
c3e00e2608
commit
f890d42019
@ -422,8 +422,7 @@ func TestRunErrorCreate(t *testing.T) {
|
||||
b.image = &docker.Image{ID: "c3ab8ff137"}
|
||||
b.Build = &script.Build{}
|
||||
b.Repo = &repo.Repo{}
|
||||
|
||||
if err := b.run(); err != docker.ErrBadRequest {
|
||||
if err := b.run(); err == nil || err.Error() != "Error: Failed to create build container. Bad Request" {
|
||||
t.Errorf("Expected error when trying to create build container")
|
||||
}
|
||||
}
|
||||
@ -456,7 +455,7 @@ func TestRunErrorStart(t *testing.T) {
|
||||
b.Build = &script.Build{}
|
||||
b.Repo = &repo.Repo{}
|
||||
|
||||
if err := b.run(); err != docker.ErrBadRequest {
|
||||
if err := b.run(); err == nil || err.Error() != "Error: Failed to start build container. Bad Request" {
|
||||
t.Errorf("Expected error when trying to start build container")
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user