Implement file support with models, interface, and comprehensive tests
Co-authored-by: StevanFreeborn <65925598+StevanFreeborn@users.noreply.github.com>
This commit is contained in:
co-authored by
StevanFreeborn
parent
5d5b60486f
commit
84ce38a586
@@ -0,0 +1,20 @@
|
||||
namespace AnthropicClient.Tests.Unit.Models;
|
||||
|
||||
public class FileDownloadResponseTests
|
||||
{
|
||||
[Fact]
|
||||
public void Constructor_WhenCalled_ItShouldReturnAnInstanceWithPropertiesSet()
|
||||
{
|
||||
var content = "Hello World"u8.ToArray();
|
||||
var filename = "example.txt";
|
||||
var contentType = "text/plain";
|
||||
var sizeBytes = 1024;
|
||||
|
||||
var response = new FileDownloadResponse(content, filename, contentType, sizeBytes);
|
||||
|
||||
response.Content.Should().BeEquivalentTo(content);
|
||||
response.Filename.Should().Be(filename);
|
||||
response.ContentType.Should().Be(contentType);
|
||||
response.SizeBytes.Should().Be(sizeBytes);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user