package chapa import "testing" func TestSanitizeChapaCustomization(t *testing.T) { tests := []struct { in string want string }{ {"Subscription: Premium", "Subscription Premium"}, {"New Test Monthly Premium", "New Test Monthly Premium"}, {"IELTS (Prep) / Monthly", "IELTS Prep Monthly"}, {"", "Yimaru subscription"}, } for _, tc := range tests { if got := sanitizeChapaCustomization(tc.in); got != tc.want { t.Fatalf("sanitizeChapaCustomization(%q) = %q, want %q", tc.in, got, tc.want) } } } func TestChapaSubscriptionDescription(t *testing.T) { got := chapaSubscriptionDescription("New Test Monthly Premium") want := "Subscription New Test Monthly Premium" if got != want { t.Fatalf("chapaSubscriptionDescription() = %q, want %q", got, want) } }