summaryrefslogtreecommitdiff
path: root/internal/comic/localization_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'internal/comic/localization_test.go')
-rw-r--r--internal/comic/localization_test.go26
1 files changed, 25 insertions, 1 deletions
diff --git a/internal/comic/localization_test.go b/internal/comic/localization_test.go
index a1609f3..8855732 100644
--- a/internal/comic/localization_test.go
+++ b/internal/comic/localization_test.go
@@ -1,6 +1,9 @@
package comic
-import "testing"
+import (
+ "strings"
+ "testing"
+)
func TestLocalizedBrandName(t *testing.T) {
t.Parallel()
@@ -40,3 +43,24 @@ func TestValidateNoPromptLeakage(t *testing.T) {
t.Fatal("validateNoPromptLeakage() error = nil, want prompt leakage rejection")
}
}
+
+func TestFindImageLeakMarker(t *testing.T) {
+ t.Parallel()
+
+ if marker, ok := findImageLeakMarker("calm text"); ok || marker != "" {
+ t.Fatalf("findImageLeakMarker() = %q, %v, want no match", marker, ok)
+ }
+ if marker, ok := findImageLeakMarker("mandatory language rule"); !ok || marker != "mandatory language rule" {
+ t.Fatalf("findImageLeakMarker() = %q, %v, want mandatory language rule match", marker, ok)
+ }
+}
+
+func TestComicStylesStayComic(t *testing.T) {
+ t.Parallel()
+
+ for _, style := range comicStyles {
+ if strings.Contains(strings.ToLower(style), "ultra realistic") || strings.Contains(strings.ToLower(style), "photograph") {
+ t.Fatalf("comicStyles contains hybrid or photorealistic style: %q", style)
+ }
+ }
+}