summaryrefslogtreecommitdiff
path: root/test/perf/poolload.py
diff options
context:
space:
mode:
authorJason Kirtland <jek@discorporate.us>2008-01-12 22:03:42 +0000
committerJason Kirtland <jek@discorporate.us>2008-01-12 22:03:42 +0000
commit17d3c8764e020379e54053bca0b0a2bc71d48aa0 (patch)
tree0b46f1ddc57292b8f5bfbc28ab1679230f63e426 /test/perf/poolload.py
parentc194962019d1bc7322e20b82c33aa1bab3bc2a28 (diff)
downloadsqlalchemy-17d3c8764e020379e54053bca0b0a2bc71d48aa0.tar.gz
- testbase is gone, replaced by testenv
- Importing testenv has no side effects- explicit functions provide similar behavior to the old immediate behavior of testbase - testing.db has the configured db - Fixed up the perf/* scripts
Diffstat (limited to 'test/perf/poolload.py')
-rw-r--r--test/perf/poolload.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/test/perf/poolload.py b/test/perf/poolload.py
index 1a2ff6978..8d66da84f 100644
--- a/test/perf/poolload.py
+++ b/test/perf/poolload.py
@@ -1,11 +1,11 @@
# load test of connection pool
-
-import testbase
+import testenv; testenv.configure_for_tests()
+import thread, time
from sqlalchemy import *
import sqlalchemy.pool as pool
-import thread,time
+from testlib import testing
-db = create_engine(testbase.db.url, pool_timeout=30, echo_pool=True)
+db = create_engine(testing.db.url, pool_timeout=30, echo_pool=True)
metadata = MetaData(db)
users_table = Table('users', metadata,
@@ -30,8 +30,8 @@ def runfast():
# time.sleep(.005)
# result.close()
print "runfast cycle complete"
-
-#thread.start_new_thread(runslow, ())
+
+#thread.start_new_thread(runslow, ())
for x in xrange(0,50):
thread.start_new_thread(runfast, ())