Skip to content

Commit

Permalink
Merge pull request #12 from StevanFreeborn/stevanfreeborn/tests/fix-i…
Browse files Browse the repository at this point in the history
…mage-test [skip ci]

tests: stop git from messing up image file
  • Loading branch information
StevanFreeborn authored Jul 20, 2024
2 parents 03ad94d + 051fa17 commit c0dec5f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
3 changes: 2 additions & 1 deletion .gitattributes
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
* text eol=crlf
*.woff binary
*.woff2 binary
*.woff2 binary
*.jpg binary
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,10 @@ public async Task CreateMessageAsync_WhenCalledWithStreamRequest_ItShouldYieldAM
[Fact]
public async Task CreateMessageAsync_WhenImageIsSent_ItShouldReturnResponse()
{
var imagePath = Path.Combine(Directory.GetCurrentDirectory(), "Files", "base64-elephant.txt");
var imagePath = Path.Combine(Directory.GetCurrentDirectory(), "Files", "elephant.jpg");
var mediaType = "image/jpeg";
var base64Data = await File.ReadAllTextAsync(imagePath);
var bytes = await File.ReadAllBytesAsync(imagePath);
var base64Data = Convert.ToBase64String(bytes);

var request = new MessageRequest(
model: AnthropicModels.Claude3Haiku,
Expand Down
1 change: 0 additions & 1 deletion tests/AnthropicClient.Tests/Files/base64-elephant.txt

This file was deleted.

0 comments on commit c0dec5f

Please sign in to comment.