From c49dfea4f288352f77030a9c6c89ab28c2130a56 Mon Sep 17 00:00:00 2001 From: Blake Niemyjski Date: Wed, 25 Sep 2024 22:19:42 -0500 Subject: [PATCH] Added missing tests --- docker-compose.yml | 9 ++++++--- .../Storage/MinioFileStorage.cs | 1 - .../Storage/MinioFileStorageTests.cs | 18 ++++++++++++++++++ 3 files changed, 24 insertions(+), 4 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index 0eaed13..c37c19f 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,8 +1,6 @@ -version: '2' - services: minio: - image: minio/minio:RELEASE.2024-03-10T02-53-48Z + image: minio/minio:RELEASE.2024-09-22T00-33-43Z command: - server - "/data" @@ -11,6 +9,11 @@ services: MINIO_ROOT_PASSWORD: "zuf+tfteSlswRu7BJ86wekitnifILbZam1KYY3TG" ports: - "9000:9000" + deploy: + resources: + limits: + memory: 1g + ready: image: andrewlock/wait-for-dependencies command: minio:9000 diff --git a/src/Foundatio.Minio/Storage/MinioFileStorage.cs b/src/Foundatio.Minio/Storage/MinioFileStorage.cs index 35e2068..08fbd10 100644 --- a/src/Foundatio.Minio/Storage/MinioFileStorage.cs +++ b/src/Foundatio.Minio/Storage/MinioFileStorage.cs @@ -3,7 +3,6 @@ using System.IO; using System.Linq; using System.Reactive.Linq; -using System.Runtime.ExceptionServices; using System.Text.RegularExpressions; using System.Threading; using System.Threading.Tasks; diff --git a/tests/Foundatio.Minio.Tests/Storage/MinioFileStorageTests.cs b/tests/Foundatio.Minio.Tests/Storage/MinioFileStorageTests.cs index a2fb73a..c915c29 100644 --- a/tests/Foundatio.Minio.Tests/Storage/MinioFileStorageTests.cs +++ b/tests/Foundatio.Minio.Tests/Storage/MinioFileStorageTests.cs @@ -42,6 +42,12 @@ public override Task CanGetFileListForSingleFolderAsync() return base.CanGetFileListForSingleFolderAsync(); } + [Fact] + public override Task CanGetFileListForSingleFileAsync() + { + return base.CanGetFileListForSingleFileAsync(); + } + [Fact] public override Task CanGetPagedFileListForSingleFolderAsync() { @@ -137,4 +143,16 @@ public override Task WillRespectStreamOffsetAsync() { return base.WillRespectStreamOffsetAsync(); } + + [Fact(Skip = "Write Stream is not yet supported")] + public override Task WillWriteStreamContentAsync() + { + return base.WillWriteStreamContentAsync(); + } + + [Fact] + public override Task CanSaveOverExistingStoredContent() + { + return base.CanSaveOverExistingStoredContent(); + } }