Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
sclevine committed Dec 5, 2024
1 parent b1ba5b6 commit 0b46c73
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/autoupdate/agent/logger.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ func (w *progressLogger) Write(p []byte) (n int, err error) {
w.n += len(p)
if w.n >= w.max*(w.l+1)/w.lines {
w.log.Log(w.ctx, w.level, "Downloading",
"name", w.name,
"file", w.name,
"progress", fmt.Sprintf("%d%%", w.n*100/w.max),
)
w.l++
Expand Down
2 changes: 1 addition & 1 deletion lib/autoupdate/agent/logger_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ func TestProgressLogger(t *testing.T) {
v, err := io.ReadAll(out)
require.NoError(t, err)
if len(v) > 0 {
e.out = fmt.Sprintf(`msg=Downloading name=test progress=%s`+"\n", e.out)
e.out = fmt.Sprintf(`msg=Downloading file=test progress=%s`+"\n", e.out)
}
require.Equal(t, e.out, string(v))
}
Expand Down

0 comments on commit 0b46c73

Please sign in to comment.