public void ShoudThrowWhenTryngToAddImageAsync() { byte[] bytes = File.ReadAllBytes(@"./MediaContent/image.jpg"); var newImageInfo = new ImageInfoRequstModel() { OriginalName = TestsConstants.ImageInfoBaseOriginalName, OriginalExtension = TestsConstants.ImageBaseExstnsion, Base64Content = Convert.ToBase64String(bytes) }; var imageRequestModel = new SaveImageRequestModel() { Title = TestsConstants.ImageBaseTitle, Description = TestsConstants.DescriptionBaseTextr, IsPrivate = false, Tags = TestsConstants.TagBaseName + "," + TestsConstants.TagBaseName + "Pesho", ImageInfo = newImageInfo }; this.controller .CallingAsync(c => c.Post(imageRequestModel)) .ShouldReturn() .HttpResponseMessage(); }