summaryrefslogtreecommitdiff
path: root/test/sql/test_defaults.py
diff options
context:
space:
mode:
authorMike Bayer <mike_mp@zzzcomputing.com>2011-03-26 19:03:11 -0400
committerMike Bayer <mike_mp@zzzcomputing.com>2011-03-26 19:03:11 -0400
commit14a2fae2398fb05f7ced56cec25e6f98307356f4 (patch)
tree6e7fde84f805d08659a96638b13edb08e681b5e9 /test/sql/test_defaults.py
parentdfd2c0fb5e1780966d0d5dfdb3d783177640f78f (diff)
downloadsqlalchemy-14a2fae2398fb05f7ced56cec25e6f98307356f4.tar.gz
- remove @testing.resolve_artifact_names, replace with direct attribute
access to the cls/self.tables/classes registries - express orm/_base.py ORMTest in terms of engine/_base.py TablesTest, factor out common steps into TablesTest, remove AltEngineTest as a separate class. will further consolidate these base classes
Diffstat (limited to 'test/sql/test_defaults.py')
-rw-r--r--test/sql/test_defaults.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/test/sql/test_defaults.py b/test/sql/test_defaults.py
index 79243ad4f..74998a77c 100644
--- a/test/sql/test_defaults.py
+++ b/test/sql/test_defaults.py
@@ -413,8 +413,9 @@ class PKDefaultTest(_base.TablesTest):
def test_regular(self):
self._test(False)
- @testing.resolve_artifact_names
def _test(self, returning):
+ t2, t1 = self.tables.t2, self.tables.t1
+
if not returning and not testing.db.dialect.implicit_returning:
engine = testing.db
else:
@@ -440,8 +441,9 @@ class PKIncrementTest(_base.TablesTest):
# TODO: add coverage for increment on a secondary column in a key
@testing.fails_on('firebird', 'Data type unknown')
- @testing.resolve_artifact_names
def _test_autoincrement(self, bind):
+ aitable = self.tables.aitable
+
ids = set()
rs = bind.execute(aitable.insert(), int1=1)
last = rs.inserted_primary_key[0]
@@ -472,11 +474,9 @@ class PKIncrementTest(_base.TablesTest):
eq_(list(bind.execute(aitable.select().order_by(aitable.c.id))),
[(1, 1, None), (2, None, 'row 2'), (3, 3, 'row 3'), (4, 4, None)])
- @testing.resolve_artifact_names
def test_autoincrement_autocommit(self):
self._test_autoincrement(testing.db)
- @testing.resolve_artifact_names
def test_autoincrement_transaction(self):
con = testing.db.connect()
tx = con.begin()