From: Mike Bayer Date: Sun, 18 Nov 2007 07:23:00 +0000 (+0000) Subject: some wide zoomark ranges... X-Git-Tag: rel_0_4_1~12 X-Git-Url: http://git.ipfire.org/gitweb/gitweb.cgi?a=commitdiff_plain;h=95807fd2872394092982a648fe6313c2e7d21531;p=thirdparty%2Fsqlalchemy%2Fsqlalchemy.git some wide zoomark ranges... --- diff --git a/lib/sqlalchemy/sql/compiler.py b/lib/sqlalchemy/sql/compiler.py index 1401170693..dd6f0dddde 100644 --- a/lib/sqlalchemy/sql/compiler.py +++ b/lib/sqlalchemy/sql/compiler.py @@ -465,13 +465,13 @@ class DefaultCompiler(engine.Compiled): if asfrom: stack_entry['is_selected_from'] = stack_entry['is_subquery'] = True column_clause_args = {} - elif self.stack and self.stack[-1].get('select'): + elif self.stack and 'select' in self.stack[-1]: stack_entry['is_subquery'] = True column_clause_args = {} else: column_clause_args = {'typemap':self.typemap, 'column_labels':self.column_labels} - if self.stack and self.stack[-1].get('from'): + if self.stack and 'from' in self.stack[-1]: existingfroms = self.stack[-1]['from'] else: existingfroms = None diff --git a/test/profiling/zoomark.py b/test/profiling/zoomark.py index 4f1a4d2820..8503ddc1fc 100644 --- a/test/profiling/zoomark.py +++ b/test/profiling/zoomark.py @@ -21,7 +21,7 @@ class ZooMarkTest(testing.AssertMixin): """ @testing.supported('postgres') - @profiling.profiled('create', call_range=(1610, 2000), always=True) + @profiling.profiled('create', call_range=(1500, 1880), always=True) def test_1_create_tables(self): global metadata metadata = MetaData(testbase.db) @@ -50,7 +50,7 @@ class ZooMarkTest(testing.AssertMixin): metadata.create_all() @testing.supported('postgres') - @profiling.profiled('populate', call_range=(2970, 4400), always=True) + @profiling.profiled('populate', call_range=(2800, 3700), always=True) def test_1a_populate(self): Zoo = metadata.tables['Zoo'] Animal = metadata.tables['Animal'] @@ -118,7 +118,7 @@ class ZooMarkTest(testing.AssertMixin): MotherID=bai_yun) @testing.supported('postgres') - @profiling.profiled('insert', call_range=(160, 250), always=True) + @profiling.profiled('insert', call_range=(150, 220), always=True) def test_2_insert(self): Animal = metadata.tables['Animal'] i = Animal.insert() @@ -274,7 +274,7 @@ class ZooMarkTest(testing.AssertMixin): assert SDZ['Founded'] == datetime.date(1935, 9, 13) @testing.supported('postgres') - @profiling.profiled('multiview', call_range=(2400, 2600), always=True) + @profiling.profiled('multiview', call_range=(2300, 2500), always=True) def test_7_multiview(self): Zoo = metadata.tables['Zoo'] Animal = metadata.tables['Animal']