From: Mike Bayer Date: Sat, 28 Dec 2013 21:37:22 +0000 (-0500) Subject: - fix the insert from select test to use a non-autoinc table X-Git-Tag: rel_0_8_5~56 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=a6905c82523a507b143625e41392a538d2472fb3;p=thirdparty%2Fsqlalchemy%2Fsqlalchemy.git - fix the insert from select test to use a non-autoinc table --- diff --git a/lib/sqlalchemy/testing/suite/test_insert.py b/lib/sqlalchemy/testing/suite/test_insert.py index c9f16b0e3b..d55e462729 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"), ] )