public async Task RemoveFileDataAsyncMethodCallsCorrectServiceMethodTest()
        {
            var fileDataId = Guid.NewGuid();
            var mockFilesPersistenceService = new Mock<IFilesPersistenceService>();
            var persistenceController = new FilesPersistenceController(mockFilesPersistenceService.Object);

            await persistenceController.DeleteFileDataAsync(fileDataId);
            mockFilesPersistenceService.Verify(m => m.DeleteFileDataAsync(fileDataId), Times.Once());
        }
        public async Task RemoveFileDataAsyncMethodReturnsCorrectTypeTest()
        {
            var fileDataId = Guid.NewGuid();
            var mockFilesPersistenceService = new Mock<IFilesPersistenceService>();
            var persistenceController = new FilesPersistenceController(mockFilesPersistenceService.Object);

            var result = await persistenceController.DeleteFileDataAsync(fileDataId);
            Assert.AreEqual(typeof(OkResult), result.GetType());
        }
        public async Task GetFilesDataAsyncMethodReturnsCorrectTypeTest()
        {
            var fileDataId = Guid.NewGuid();
            var mockFilesPersistenceService = new Mock<IFilesPersistenceService>();
            var persistenceController = new FilesPersistenceController(mockFilesPersistenceService.Object);

            var result = await persistenceController.GetFileDataAsync(fileDataId);
            Assert.AreEqual(typeof(OkNegotiatedContentResult<FilePersistenceServiceResponseDto>), result.GetType());
        }
        public async Task SaveFileDataAsyncMethodReturnsCorrectTypeTest()
        {
            var byteArray = new byte[] { 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20 };
            var fileBlobServiceRequestDto = new FilePersistenceServiceRequestDto { Bytes = byteArray, ContentType = "img", FileName = "MyTest.img" };

            var mockFilesPersistenceService = new Mock<IFilesPersistenceService>();
            var persistenceController = new FilesPersistenceController(mockFilesPersistenceService.Object);

            var result = await persistenceController.SaveFileDataAsync(fileBlobServiceRequestDto);
            Assert.AreEqual(typeof(OkNegotiatedContentResult<FilePersistenceServiceResponseDto>), result.GetType());
        }
        public async Task SaveFileDataAsyncMethodCallsCorrectServiceMethodTest()
        {
            var byteArray = new byte[] { 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20 };
            var fileBlobServiceRequestDto = new FilePersistenceServiceRequestDto { Bytes = byteArray, ContentType = "img", FileName = "MyTest.img" };

            var mockFilesPersistenceService = new Mock<IFilesPersistenceService>();
            var persistenceController = new FilesPersistenceController(mockFilesPersistenceService.Object);

            var fileDataId = await persistenceController.SaveFileDataAsync(fileBlobServiceRequestDto);
            mockFilesPersistenceService.Verify(m => m.SaveFileDataAsync(fileBlobServiceRequestDto.Bytes, fileBlobServiceRequestDto.ContentType, fileBlobServiceRequestDto.FileName), Times.Once());
        }