From: Mike Bayer Date: Sat, 4 Oct 2014 21:47:53 +0000 (-0400) Subject: Merge branch 'reflect-unique-constraints' of https://bitbucket.org/jerdfelt/sqlalchem... X-Git-Tag: rel_1_0_0b1~70^2~48 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f7dee1380c40f3e73868a136aae5d18e976aa757;p=thirdparty%2Fsqlalchemy%2Fsqlalchemy.git Merge branch 'reflect-unique-constraints' of https://bitbucket.org/jerdfelt/sqlalchemy into pr30 --- f7dee1380c40f3e73868a136aae5d18e976aa757 diff --cc lib/sqlalchemy/testing/suite/test_reflection.py index 60db9eb474,bd0be57380..08b858b472 --- a/lib/sqlalchemy/testing/suite/test_reflection.py +++ b/lib/sqlalchemy/testing/suite/test_reflection.py @@@ -497,13 -485,14 +497,15 @@@ class ComponentReflectionTest(fixtures. self._test_get_unique_constraints() @testing.requires.temp_table_reflection + @testing.requires.unique_constraint_reflection def test_get_temp_table_unique_constraints(self): insp = inspect(self.metadata.bind) - eq_( - insp.get_unique_constraints('user_tmp'), - [{'column_names': ['name'], 'name': 'user_tmp_uq'}] - ) + reflected = insp.get_unique_constraints('user_tmp') + for refl in reflected: + # Different dialects handle duplicate index and constraints + # differently, so ignore this flag + refl.pop('duplicates_index', None) + eq_(reflected, [{'column_names': ['name'], 'name': 'user_tmp_uq'}]) @testing.requires.temp_table_reflection def test_get_temp_table_indexes(self):