From 71b974d4f850b1e8682826d2e572c07cc6c3edd8 Mon Sep 17 00:00:00 2001 From: Nicola Murino Date: Wed, 19 Jun 2024 10:40:15 +0200 Subject: [PATCH] fix test case failure on macOS with bolt provider Signed-off-by: Nicola Murino --- internal/webdavd/webdavd_test.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/internal/webdavd/webdavd_test.go b/internal/webdavd/webdavd_test.go index 0df928be..7a6127ea 100644 --- a/internal/webdavd/webdavd_test.go +++ b/internal/webdavd/webdavd_test.go @@ -642,9 +642,6 @@ func TestBasicHandling(t *testing.T) { } func TestBasicHandlingCryptFs(t *testing.T) { - if runtime.GOOS == "darwin" && dataprovider.GetProviderStatus().Driver == "bolt" { - t.Skip("this test must be fixed on macOS when using the bolt provider") - } u := getTestUserWithCryptFs() u.QuotaSize = 6553600 user, _, err := httpdtest.AddUser(u, http.StatusCreated) @@ -670,6 +667,8 @@ func TestBasicHandlingCryptFs(t *testing.T) { localDownloadPath := filepath.Join(homeBasePath, testDLFileName) err = downloadFile(testFileName, localDownloadPath, testFileSize, client) assert.NoError(t, err) + assert.Eventually(t, func() bool { return len(common.Connections.GetStats("")) == 0 }, + 1*time.Second, 100*time.Millisecond) user, _, err = httpdtest.GetUserByUsername(user.Username, http.StatusOK) assert.NoError(t, err) assert.Equal(t, expectedQuotaFiles, user.UsedQuotaFiles)