Ai
1 Star 0 Fork 0

GarlicBoris/gozero-utils

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
no_generator_test.go 383 Bytes
一键复制 编辑 原始数据 按行查看 历史
yanwc 提交于 2024-06-08 20:40 +08:00 . refactor
package utils
import (
"context"
"fmt"
"testing"
"github.com/redis/go-redis/v9"
)
func TestGenerateNo(t *testing.T) {
client := redis.NewClient(&redis.Options{
Addr: "127.0.0.1:6379",
Password: "123456",
DB: 1,
})
for i := 0; i < 100; i++ {
no, err := GenerateNo(context.Background(), client, "U")
if err != nil {
t.Fail()
}
fmt.Println(no)
}
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Go
1
https://gitee.com/yanwc/gozero-utils.git
git@gitee.com:yanwc/gozero-utils.git
yanwc
gozero-utils
gozero-utils
v1.3.78

搜索帮助