mirror of
https://github.com/restic/restic.git
synced 2026-11-04 14:29:21 +00:00
ui/progress: unexport NoopPrinter and add New* function
This commit is contained in:
1 parent
e8ed2434cd
commit
0bbfb072af
13 files changed
+41
-35
No files matched your search
@@ -13,7 +13,7 @@ import (
|
||||
|
||||
type mockPrinter struct {
|
||||
sync.Mutex
|
||||
progress.NoopPrinter
|
||||
progress.Printer
|
||||
dirUnchanged, fileNew bool
|
||||
id restic.ID
|
||||
}
|
||||
@@ -48,7 +48,7 @@ func (p *mockPrinter) Reset() {}
|
||||
func TestProgress(t *testing.T) {
|
||||
t.Parallel()
|
||||
|
||||
prnt := &mockPrinter{}
|
||||
prnt := &mockPrinter{Printer: progress.NewNoopPrinter()}
|
||||
prog := NewProgress(prnt, time.Millisecond)
|
||||
|
||||
prog.StartFile("foo")
|
||||
|
||||
Reference in new issue
Block a user