Skip to content

Commit

Permalink
use non-default width in spinner tests
Browse files Browse the repository at this point in the history
  • Loading branch information
black-night-heron committed Jun 6, 2024
1 parent 2b335f6 commit d42b001
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions progressbar_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ func ExampleOptionClearOnFinish() {

func TestSpinnerClearOnFinish(t *testing.T) {
buf := strings.Builder{}
bar := NewOptions(-1, OptionShowCount(), OptionShowBytes(true), OptionShowIts(), OptionClearOnFinish(), OptionSetWriter(&buf))
bar := NewOptions(-1, OptionSetWidth(100), OptionShowCount(), OptionShowBytes(true), OptionShowIts(), OptionClearOnFinish(), OptionSetWriter(&buf))
bar.Reset()
time.Sleep(1 * time.Second)
bar.Add(10)
Expand All @@ -121,7 +121,7 @@ func ExampleProgressBar_Finish() {

func TestSpinnerFinish(t *testing.T) {
buf := strings.Builder{}
bar := NewOptions(-1, OptionShowCount(), OptionShowBytes(true), OptionShowIts(), OptionSetWriter(&buf))
bar := NewOptions(-1, OptionSetWidth(100), OptionShowCount(), OptionShowBytes(true), OptionShowIts(), OptionSetWriter(&buf))
bar.Reset()
time.Sleep(1 * time.Second)
bar.Add(10)
Expand Down

0 comments on commit d42b001

Please sign in to comment.