diff options
author | Mike Bayer <mike_mp@zzzcomputing.com> | 2013-12-28 16:37:22 -0500 |
---|---|---|
committer | Mike Bayer <mike_mp@zzzcomputing.com> | 2013-12-28 16:37:22 -0500 |
commit | d8bc6673c0bb34258bf4c54699ceede777664600 (patch) | |
tree | 62905fdee27174301006cff462882a3e72a352d6 /lib/sqlalchemy/testing/suite/test_insert.py | |
parent | 8d1ec3cc7fc36c08f6bd9a8881ceb86a057f79aa (diff) | |
download | sqlalchemy-d8bc6673c0bb34258bf4c54699ceede777664600.tar.gz |
- fix the insert from select test to use a non-autoinc table
Diffstat (limited to 'lib/sqlalchemy/testing/suite/test_insert.py')
-rw-r--r-- | lib/sqlalchemy/testing/suite/test_insert.py | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/lib/sqlalchemy/testing/suite/test_insert.py b/lib/sqlalchemy/testing/suite/test_insert.py index deda63b24..5732e37ec 100644 --- a/lib/sqlalchemy/testing/suite/test_insert.py +++ b/lib/sqlalchemy/testing/suite/test_insert.py @@ -82,6 +82,10 @@ class InsertBehaviorTest(fixtures.TablesTest): test_needs_autoincrement=True), Column('data', String(50)) ) + Table('manual_pk', metadata, + Column('id', Integer, primary_key=True, autoincrement=False), + Column('data', String(50)) + ) def test_autoclose_on_insert(self): if requirements.returning.enabled: @@ -124,13 +128,13 @@ class InsertBehaviorTest(fixtures.TablesTest): @requirements.insert_from_select def test_insert_from_select(self): - table = self.tables.autoinc_pk + table = self.tables.manual_pk config.db.execute( table.insert(), [ - dict(data="data1"), - dict(data="data2"), - dict(data="data3"), + dict(id=1, data="data1"), + dict(id=2, data="data2"), + dict(id=3, data="data3"), ] ) |