summaryrefslogtreecommitdiff
path: root/test/aaa_profiling/test_resultset.py
diff options
context:
space:
mode:
authorMike Bayer <mike_mp@zzzcomputing.com>2012-08-11 15:51:08 -0400
committerMike Bayer <mike_mp@zzzcomputing.com>2012-08-11 15:51:08 -0400
commit48c9993b65dfee9ab36f84dbcf8c27631fb38950 (patch)
tree7289f92a978dc7c39cde783f846e7e5b2d1c7ff0 /test/aaa_profiling/test_resultset.py
parent3986fd7626ff29f7debfc72f63ba22235e31ed7e (diff)
downloadsqlalchemy-48c9993b65dfee9ab36f84dbcf8c27631fb38950.tar.gz
OK! let's turn this around completely. Forget making a single count across
all platforms. let's instead store callcounts for *all* observed platforms in a datafile. Will try to get enough platforms in the file for jenkins to have meaningful results. for platforms not in the file, it's just skiptest.
Diffstat (limited to 'test/aaa_profiling/test_resultset.py')
-rw-r--r--test/aaa_profiling/test_resultset.py18
1 files changed, 7 insertions, 11 deletions
diff --git a/test/aaa_profiling/test_resultset.py b/test/aaa_profiling/test_resultset.py
index 4cd213389..daee84b97 100644
--- a/test/aaa_profiling/test_resultset.py
+++ b/test/aaa_profiling/test_resultset.py
@@ -6,17 +6,15 @@ NUM_RECORDS = 1000
class ResultSetTest(fixtures.TestBase, AssertsExecutionResults):
- __requires__ = 'cpython', 'cextensions',
- __only_on__ = 'sqlite'
@classmethod
def setup_class(cls):
global t, t2, metadata
metadata = MetaData(testing.db)
- t = Table('table', metadata, *[Column('field%d' % fnum, String)
+ t = Table('table', metadata, *[Column('field%d' % fnum, String(50))
for fnum in range(NUM_FIELDS)])
t2 = Table('table2', metadata, *[Column('field%d' % fnum,
- Unicode) for fnum in range(NUM_FIELDS)])
+ Unicode(50)) for fnum in range(NUM_FIELDS)])
def setup(self):
metadata.create_all()
@@ -34,25 +32,23 @@ class ResultSetTest(fixtures.TestBase, AssertsExecutionResults):
def teardown(self):
metadata.drop_all()
- @profiling.function_call_count(316)
+ @profiling.function_call_count()
def test_string(self):
[tuple(row) for row in t.select().execute().fetchall()]
- @profiling.function_call_count(316)
+ @profiling.function_call_count()
def test_unicode(self):
[tuple(row) for row in t2.select().execute().fetchall()]
def test_contains_doesnt_compile(self):
row = t.select().execute().first()
c1 = Column('some column', Integer) + Column("some other column", Integer)
- @profiling.function_call_count(9, variance=.15)
+ @profiling.function_call_count()
def go():
c1 in row
go()
class ExecutionTest(fixtures.TestBase):
- __requires__ = 'cpython',
- __only_on__ = 'sqlite'
def test_minimal_connection_execute(self):
# create an engine without any instrumentation.
@@ -61,7 +57,7 @@ class ExecutionTest(fixtures.TestBase):
# ensure initial connect activities complete
c.execute("select 1")
- @profiling.function_call_count(40, variance=.10)
+ @profiling.function_call_count()
def go():
c.execute("select 1")
go()
@@ -72,7 +68,7 @@ class ExecutionTest(fixtures.TestBase):
# ensure initial connect activities complete
e.execute("select 1")
- @profiling.function_call_count(62, variance=.5)
+ @profiling.function_call_count()
def go():
e.execute("select 1")
go()