mirror of
https://github.com/gofiber/storage.git
synced 2025-11-03 02:43:22 +08:00
fix(minio): capture the errors when minio deletes a bucket
This commit is contained in:
@@ -237,6 +237,18 @@ func Test_Reset(t *testing.T) {
|
||||
require.Zero(t, len(result))
|
||||
}
|
||||
|
||||
func Test_Reset_Not_Exists_Bucket(t *testing.T) {
|
||||
testStore := newTestStore(t)
|
||||
defer testStore.Close()
|
||||
|
||||
err := testStore.RemoveBucket()
|
||||
require.NoError(t, err)
|
||||
|
||||
err = testStore.Reset()
|
||||
require.Error(t, err)
|
||||
require.EqualError(t, err, "The specified bucket does not exist")
|
||||
}
|
||||
|
||||
func Test_Close(t *testing.T) {
|
||||
testStore := newTestStore(t)
|
||||
require.NoError(t, testStore.Close())
|
||||
|
||||
Reference in New Issue
Block a user