-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtests.py
More file actions
29 lines (21 loc) · 725 Bytes
/
tests.py
File metadata and controls
29 lines (21 loc) · 725 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
'''strange tests'''
from subsystems.pathing import bezierPathCoords, straightPathCoords
import time
import random
from subsystems.render import *
from settings import *
from subsystems.fancy import display
tests = 0
total = 0
while tests<1000:
text = "".join([x for x in [("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789!@#$%^&*()-_=+")[random.randrange(0,75)] for x in range(100)]])
start = time.time()
img = display(text, "s")
end = time.time()
total+=end-start
tests+=1
print(f"{tests} tests | avg: {total/tests} seconds")
# coords = [(0,0),(8,4),(-4,6),(-8,0),(-8,-6)]
# coords = bezierPathCoords(coords,30)
# print(coords)
# merge(PLACEHOLDER_IMAGE, PLACEHOLDER_IMAGE)