Skip to content

Commit d88cec5

Browse files
committed
Fix: pkg/gobash/gobash_test.go:21:11: non-constant format string in call to (*testing.common).Logf
1 parent 5b49c9c commit d88cec5

File tree

5 files changed

+6
-6
lines changed

5 files changed

+6
-6
lines changed

pkg/aicli/chatgpt/client_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ func TestClient_SendStream(t *testing.T) {
4646
ctx, _ := context.WithTimeout(context.Background(), 5*time.Second)
4747
reply := client.SendStream(ctx, "Which model did you use to answer the question?")
4848
for content := range reply.Content {
49-
fmt.Printf(content)
49+
fmt.Print(content)
5050
}
5151
if reply.Err != nil {
5252
t.Log(reply.Err)

pkg/aicli/deepseek/client_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ func TestClient_SendStream(t *testing.T) {
4646
ctx, _ := context.WithTimeout(context.Background(), 10*time.Second)
4747
answer := client.SendStream(ctx, genericRoleDescZH)
4848
for content := range answer.Content {
49-
fmt.Printf(content)
49+
fmt.Print(content)
5050
}
5151
if answer.Err != nil {
5252
t.Log(answer.Err)

pkg/aicli/gemini/client_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ func TestClient_SendStream(t *testing.T) {
4141
ctx, _ := context.WithTimeout(context.Background(), 5*time.Second)
4242
reply := client.SendStream(ctx, "Which model did you use to answer the question?")
4343
for content := range reply.Content {
44-
fmt.Printf(content)
44+
fmt.Print(content)
4545
}
4646
if reply.Err != nil {
4747
t.Log(reply.Err)

pkg/conf/parse_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,10 @@ func Test_hideSensitiveFields(t *testing.T) {
2727
keywords = append(keywords, `"dsn"`, `"password"`, `"name"`)
2828
str := Show(c, keywords...)
2929

30-
fmt.Printf(hideSensitiveFields(str))
30+
fmt.Print(hideSensitiveFields(str))
3131

3232
str = "\ndefault:[email protected]:6379/0\n"
33-
fmt.Printf(hideSensitiveFields(str))
33+
fmt.Print(hideSensitiveFields(str))
3434
}
3535

3636
// test listening for configuration file updates

pkg/gobash/gobash_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ func TestRun(t *testing.T) {
2525
t.Logf("pid: %d", pid)
2626
continue
2727
}
28-
t.Logf(v)
28+
t.Log(v)
2929
}
3030
if result.Err != nil {
3131
t.Logf("execute command failed, %v", result.Err)

0 commit comments

Comments
 (0)