Fix: failed unit test

feat-album
HFO4 4 years ago
parent 5a66af3105
commit 4cf6c81534

@ -75,8 +75,8 @@ func TestHandler_Delete(t *testing.T) {
asserts.NoError(err) asserts.NoError(err)
list, err = handler.Delete(ctx, []string{"test.file", "test.notexist"}) list, err = handler.Delete(ctx, []string{"test.file", "test.notexist"})
file.Close() file.Close()
asserts.Equal([]string{"test.file"}, list) asserts.Equal([]string{}, list)
asserts.Error(err) asserts.NoError(err)
list, err = handler.Delete(ctx, []string{"test.notexist"}) list, err = handler.Delete(ctx, []string{"test.notexist"})
asserts.Equal([]string{}, list) asserts.Equal([]string{}, list)
@ -86,8 +86,8 @@ func TestHandler_Delete(t *testing.T) {
asserts.NoError(err) asserts.NoError(err)
list, err = handler.Delete(ctx, []string{"test.file"}) list, err = handler.Delete(ctx, []string{"test.file"})
_ = file.Close() _ = file.Close()
asserts.Equal([]string{"test.file"}, list) asserts.Equal([]string{}, list)
asserts.Error(err) asserts.NoError(err)
} }
func TestHandler_Get(t *testing.T) { func TestHandler_Get(t *testing.T) {

Loading…
Cancel
Save