(new): rich message support
Golang lint / lint (pull_request) Successful in 1m20s
Golang lint / lint (push) Successful in 4m8s

(fix): runtime reliability
(tests): regression coverage
(doc): v1.1 release notes
This commit is contained in:
2026-08-12 16:34:44 +03:00
parent 48ddf66540
commit f03a081ed6
83 changed files with 6122 additions and 1925 deletions
+21
View File
@@ -0,0 +1,21 @@
package laniakea
import (
"strings"
"testing"
)
func TestGenerateTokenUsesRawURLAlphabet(t *testing.T) {
token, err := generateToken(32)
if err != nil {
t.Fatalf("generateToken returned error: %v", err)
}
if strings.Contains(token, "=") {
t.Fatalf("token contains forbidden padding: %q", token)
}
for _, r := range token {
if !strings.ContainsRune("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_-", r) {
t.Fatalf("token contains a character forbidden by Telegram: %q", r)
}
}
}