Skip to content

Commit e06d15d

Browse files
committed
added SetColumn and ChangeBubbleShape tests.
1 parent 851afc3 commit e06d15d

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed

bw_test.go

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,3 +29,29 @@ func TestDemo(t *testing.T) {
2929
bw.Redisplay()
3030
}
3131
}
32+
33+
func TestSetColumn(t *testing.T) {
34+
numbers := 220
35+
36+
bw := NewBubbleWrap(numbers).SetColumn(60)
37+
bw.Display()
38+
39+
for i := 0; i < numbers; i++ {
40+
time.Sleep(10 * time.Millisecond)
41+
bw.Pop(i)
42+
bw.Redisplay()
43+
}
44+
}
45+
46+
func TestChangeBubbleShape(t *testing.T) {
47+
numbers := 220
48+
49+
bw := NewBubbleWrap(numbers).ChangeBubbleShape("o", "x")
50+
bw.Display()
51+
52+
for i := 0; i < numbers; i++ {
53+
time.Sleep(10 * time.Millisecond)
54+
bw.Pop(i)
55+
bw.Redisplay()
56+
}
57+
}

0 commit comments

Comments
 (0)