Apply .gitignore rules

This commit is contained in:
皮蛋13361098506
2025-01-06 16:21:36 +08:00
parent 1b77f62820
commit ccd2c530cf
580 changed files with 69806 additions and 0 deletions

View File

@@ -0,0 +1,49 @@
package contextcheckMgr
import (
"fmt"
"testing"
)
func TestCheck(t *testing.T) {
//content, account, nickname, extLon1, extLon2, extStr1, extStr2, ip
var content = "文本检查测试"
var account = "000e6a6e-7cfc-4da7-81a2-ef3a5d24c586"
var nickname = "不仅仅是喜欢"
var extLon1 int64 = 10001
//var extLon2 = "游戏内聊天"
var extStr1 = "10001铁血丹心"
var extStr2 = "5DF67DD225640567D4D0B6FE273262B5"
var ip = "113.116.66.45"
//设置完全正确的参数
code, err := TextCheck(content, account, nickname, extStr1, extStr2, ip, extLon1)
if err != nil {
t.Errorf("There should be no error, but now there is:%v", err)
return
}
fmt.Printf("检测完成,状态码为:%d\n", code)
content = "修炼发轮功"
code, err = TextCheck(content, account, nickname, extStr1, extStr2, ip, extLon1)
if err != nil {
t.Errorf("There should be no error, but now there is:%v", err)
return
}
fmt.Printf("检测完成,状态码为:%d\n", code)
content = ""
code, err = TextCheck(content, account, nickname, extStr1, extStr2, ip, extLon1)
if err != nil {
t.Errorf("There should be no error, but now there is:%v", err)
return
}
fmt.Printf("检测完成,状态码为:%d\n", code)
}