aboutsummaryrefslogtreecommitdiff
path: root/wqflask/maintenance/print_benchmark.py
diff options
context:
space:
mode:
authorPjotr Prins2016-06-17 06:15:59 +0000
committerPjotr Prins2016-06-17 06:15:59 +0000
commit9ed3c1e6ed99c56d77fd5d90ff42f9acfe7ace68 (patch)
treefabca0ec5073e2c17da425eeeb7e40a9e15c564f /wqflask/maintenance/print_benchmark.py
parent497b72d3496b9368167616774e58250598d7bd83 (diff)
downloadgenenetwork2-9ed3c1e6ed99c56d77fd5d90ff42f9acfe7ace68.tar.gz
Removed trailing spaces in .py and .js files
Diffstat (limited to 'wqflask/maintenance/print_benchmark.py')
-rwxr-xr-xwqflask/maintenance/print_benchmark.py16
1 files changed, 8 insertions, 8 deletions
diff --git a/wqflask/maintenance/print_benchmark.py b/wqflask/maintenance/print_benchmark.py
index 540e0904..ae327cf3 100755
--- a/wqflask/maintenance/print_benchmark.py
+++ b/wqflask/maintenance/print_benchmark.py
@@ -9,34 +9,34 @@ from pprint import pformat as pf
class TheCounter(object):
Counters = {}
-
+
def __init__(self):
start_time = time.time()
for counter in range(170000):
self.print_it(counter)
self.time_took = time.time() - start_time
- TheCounter.Counters[self.__class__.__name__] = self.time_took
+ TheCounter.Counters[self.__class__.__name__] = self.time_took
-class PrintAll(TheCounter):
+class PrintAll(TheCounter):
def print_it(self, counter):
print(counter)
-
+
class PrintSome(TheCounter):
def print_it(self, counter):
if counter % 1000 == 0:
print(counter)
-
+
class PrintNone(TheCounter):
def print_it(self, counter):
pass
-
-
+
+
def new_main():
print("Running new_main")
tests = [PrintAll, PrintSome, PrintNone]
for test in tests:
test()
-
+
print(pf(TheCounter.Counters))
if __name__ == '__main__':