new-openstackcheck-mk2/test.py

16 lines
411 B
Python

import time
timingText=""
tic = time.perf_counter()
import requests
toc = time.perf_counter()
timingText +=(f"Queried projects in {toc - tic:0.4f} seconds\n")
x=requests.get("http://google.com")
toc = time.perf_counter()
time.sleep(1)
timingText +=(f"Queried projects in {toc - tic:0.4f} seconds\n")
toc = time.perf_counter()
timingText +=(f"Queried projects in {toc - tic:0.4f} seconds\n")
print(timingText)