Add basic test for Records.Cover module

This commit is contained in:
Claudio Ortolina
2024-11-29 22:08:40 +00:00
parent d9773bf45d
commit cf51cab7ce
2 changed files with 15 additions and 0 deletions
+1
View File
@@ -1,5 +1,6 @@
defmodule MusicLibrary.Records.Cover do
@size 600
def resize(cover_data) do
{:ok, thumb} = Vix.Vips.Operation.thumbnail_buffer(cover_data, @size)
Vix.Vips.Image.write_to_buffer(thumb, ".jpg")