chore(test): 清理测试用例与类型导入
This commit is contained in:
@@ -28,9 +28,9 @@ func TestRedactText_QueryLike(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestRedactText_GOCSPX(t *testing.T) {
|
||||
in := "client_secret=GOCSPX-abcdefghijklmnopqrstuvwxyz_0123456789"
|
||||
in := "client_secret=GOCSPX-your-client-secret"
|
||||
out := RedactText(in)
|
||||
if strings.Contains(out, "abcdefghijklmnopqrstuvwxyz") {
|
||||
if strings.Contains(out, "your-client-secret") {
|
||||
t.Fatalf("expected secret redacted, got %q", out)
|
||||
}
|
||||
if !strings.Contains(out, "client_secret=***") {
|
||||
|
||||
Reference in New Issue
Block a user