Initial commit

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
2026-09-15 13:57:10 +08:00
co-authored by Claude Opus 5
commit 8679200f41
1897 changed files with 257900 additions and 0 deletions
+31
View File
@@ -0,0 +1,31 @@
package userser
import (
"testing"
"time"
"91porn-server/models/v/usermod"
"91porn-server/models/v/walletmod"
)
func TestToUserRecordListIncludesDramaExpire(t *testing.T) {
expire := time.Date(2026, 9, 26, 12, 0, 0, 0, time.UTC)
users := []usermod.User{{UID: 100001, DramaExpire: expire}}
records := toUserRecordList(
users,
map[uint64]int64{},
map[uint64]uint64{},
map[uint64]int64{},
map[uint64]walletmod.Wallet{},
map[uint64]int{},
map[uint64]int{},
)
if len(records) != 1 {
t.Fatalf("record count = %d, want 1", len(records))
}
if !records[0].DramaExpire.Equal(expire) {
t.Fatalf("dramaExpire = %s, want %s", records[0].DramaExpire, expire)
}
}