-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathtest.py
More file actions
37 lines (30 loc) · 762 Bytes
/
test.py
File metadata and controls
37 lines (30 loc) · 762 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
from loadig import Bar
from time import sleep
sleep_time = 0.2
bar = Bar(total=1000, message="Loadig...", columns=60)
for i in range(0, 1000):
sleep(sleep_time/10)
bar.update(i)
bar = Bar(total=100, message="Running test...")
sleep(1)
for i in range(0, 100):
sleep(sleep_time)
bar.update()
if i == 25:
bar.update("Does this look good?")
if i > 75:
bar.update("Going to clear in %d" % (bar.total - i))
sleep(0.5)
bar.clear()
sleep(0.5)
bar = Bar(total=100)
for i in range(0, 100):
sleep(sleep_time)
bar.update()
if i == 50:
bar.update("Did the clearing look good?")
sleep(1.0)
bar = Bar(total=100, message="This is another test...")
for i in range(0, 100):
sleep(sleep_time)
bar.update()