diff options
| author | Paul Buetow <paul@buetow.org> | 2026-04-01 20:58:40 +0300 |
|---|---|---|
| committer | Paul Buetow <paul@buetow.org> | 2026-04-01 20:58:40 +0300 |
| commit | 7e84b912c56b65c070b2bbd6b0284505ba579338 (patch) | |
| tree | ef65e80938c906e6d46d25840a90e3e293f64356 /internal/image | |
| parent | b1f5cd11496ef8a468a63fd2329a33e3046ab13a (diff) | |
Strengthen Nano Banana metadata assertion
Diffstat (limited to 'internal/image')
| -rw-r--r-- | internal/image/nanobanana_test.go | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/internal/image/nanobanana_test.go b/internal/image/nanobanana_test.go index 9c9dacd..5b4f5ef 100644 --- a/internal/image/nanobanana_test.go +++ b/internal/image/nanobanana_test.go @@ -105,11 +105,9 @@ func TestNanoBananaClient_Search_CustomPromptSkipsTextGeneration(t *testing.T) { if len(results) != 1 { t.Fatalf("expected 1 result, got %d", len(results)) } - if !strings.Contains(results[0].Description, "ябълка") { - t.Fatalf("result description = %q, want it to mention the query", results[0].Description) - } - if !strings.Contains(results[0].Description, "banana") { - t.Fatalf("result description = %q, want translation metadata from custom prompt", results[0].Description) + wantDescription := "Generated educational image for ябълка (banana)" + if results[0].Description != wantDescription { + t.Fatalf("result description = %q, want %q", results[0].Description, wantDescription) } if !strings.HasPrefix(results[0].URL, "data:image/png;base64,") { t.Fatalf("expected PNG data URI, got %q", results[0].URL) |
