Fix: image alias put query
Some checks failed
Some checks failed
This commit is contained in:
@@ -7,9 +7,11 @@ import (
|
||||
)
|
||||
|
||||
func Test_07_DeleteAlias(t *testing.T) {
|
||||
deleteId := aliases[0].Id
|
||||
|
||||
resp, err := client.R().
|
||||
Delete(fmt.Sprintf("http://localhost:8080/api/alias/%d",
|
||||
aliases[0].Id))
|
||||
deleteId))
|
||||
if err != nil || resp.StatusCode() != http.StatusOK {
|
||||
t.Logf("%+v", resp)
|
||||
t.Fatal("failed to delete alias")
|
||||
@@ -23,7 +25,10 @@ func Test_07_DeleteAlias(t *testing.T) {
|
||||
t.Fatal("failed to get aliases")
|
||||
}
|
||||
|
||||
if len(aliases) > 0 {
|
||||
t.Fatal("alias not deleted")
|
||||
for _, alias := range aliases {
|
||||
if alias.Id == deleteId {
|
||||
t.Logf("%+v", resp)
|
||||
t.Fatal("alias not deleted")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user