Commits

Mike Bayer committed 51c7005

- clean up zoomark a little and try to get new profiles written

Comments (0)

Files changed (4)

lib/sqlalchemy/testing/replay_fixture.py

         self.session = Session(engine)
 
         self.setup_engine()
-        self._run_steps(ctx=self._dummy_ctx)
-        self.teardown_engine()
-        engine.dispose()
+        try:
+            self._run_steps(ctx=self._dummy_ctx)
+        finally:
+            self.teardown_engine()
+            engine.dispose()
 
         player = lambda: dbapi_session.player()
         engine = create_engine(
         self.session = Session(engine)
 
         self.setup_engine()
-        self._run_steps(ctx=profiling.count_functions)
-        self.teardown_engine()
+        try:
+            self._run_steps(ctx=profiling.count_functions)
+        finally:
+            self.session.close()
+            engine.dispose()
 
     def setup_engine(self):
         pass

test/aaa_profiling/test_zoomark.py

     __only_on__ = 'postgresql+psycopg2'
 
     def _run_steps(self, ctx):
-        self._baseline_1_create_tables()
         with ctx():
             self._baseline_1a_populate()
         with ctx():
             self._baseline_6_editing()
         with ctx():
             self._baseline_7_multiview()
+
+    def setup_engine(self):
+        self._baseline_1_create_tables()
+
+    def teardown_engine(self):
         self._baseline_8_drop()
 
     def _baseline_1_create_tables(self):

test/aaa_profiling/test_zoomark_orm.py

     __only_on__ = 'postgresql+psycopg2'
 
     def _run_steps(self, ctx):
-        #self._baseline_1_create_tables()
         with ctx():
             self._baseline_1a_populate()
         with ctx():
             self._baseline_5_aggregates()
         with ctx():
             self._baseline_6_editing()
-        #self._baseline_7_drop()
 
     def setup_engine(self):
         self._baseline_1_create_tables()

test/profiles.txt

 
 # TEST: test.aaa_profiling.test_zoomark_orm.ZooMarkTest.test_invocation
 
-test.aaa_profiling.test_zoomark_orm.ZooMarkTest.test_invocation 2.7_postgresql_psycopg2_cextensions 5908,396,6878,19521,1118,2606
-test.aaa_profiling.test_zoomark_orm.ZooMarkTest.test_invocation 2.7_postgresql_psycopg2_nocextensions 5999,401,7110,20952,1226,2671
-test.aaa_profiling.test_zoomark_orm.ZooMarkTest.test_invocation 3.3_postgresql_psycopg2_cextensions 5816,383,6928,19676,1091,2753
-test.aaa_profiling.test_zoomark_orm.ZooMarkTest.test_invocation 3.3_postgresql_psycopg2_nocextensions 5886,388,7032,20703,1177,2659
-test.aaa_profiling.test_zoomark_orm.ZooMarkTest.test_invocation 3.4_postgresql_psycopg2_cextensions 6000,386,6716,18339,1091,2630
-test.aaa_profiling.test_zoomark_orm.ZooMarkTest.test_invocation 3.4_postgresql_psycopg2_nocextensions 6092,391,6820,19366,1177,2659
+test.aaa_profiling.test_zoomark_orm.ZooMarkTest.test_invocation 2.7_postgresql_psycopg2_cextensions 6098,399,6666,18183,1118,2606
+test.aaa_profiling.test_zoomark_orm.ZooMarkTest.test_invocation 2.7_postgresql_psycopg2_nocextensions 6169,404,6898,19614,1226,2671
+test.aaa_profiling.test_zoomark_orm.ZooMarkTest.test_invocation 3.3_postgresql_psycopg2_cextensions 6008,386,6716,18339,1091,2630
+test.aaa_profiling.test_zoomark_orm.ZooMarkTest.test_invocation 3.3_postgresql_psycopg2_nocextensions 6093,391,6820,19366,1177,2659
+test.aaa_profiling.test_zoomark_orm.ZooMarkTest.test_invocation 3.4_postgresql_psycopg2_cextensions 6007,386,6716,18339,1091,2630
+test.aaa_profiling.test_zoomark_orm.ZooMarkTest.test_invocation 3.4_postgresql_psycopg2_nocextensions 6087,391,6820,19366,1177,2659