mirror of
https://github.com/django/django.git
synced 2025-08-03 18:38:50 +00:00
Replaced set([foo, ...]) by {foo, ...} literals. Refs PR 3282.
Thanks Collin Anderson for the review.
This commit is contained in:
parent
caf5cd7ba7
commit
b2aad7b836
37 changed files with 123 additions and 122 deletions
|
@ -55,7 +55,7 @@ class IntrospectionTests(TestCase):
|
|||
def test_installed_models(self):
|
||||
tables = [Article._meta.db_table, Reporter._meta.db_table]
|
||||
models = connection.introspection.installed_models(tables)
|
||||
self.assertEqual(models, set([Article, Reporter]))
|
||||
self.assertEqual(models, {Article, Reporter})
|
||||
|
||||
def test_sequence_list(self):
|
||||
sequences = connection.introspection.sequence_list()
|
||||
|
@ -129,8 +129,8 @@ class IntrospectionTests(TestCase):
|
|||
key_columns = connection.introspection.get_key_columns(cursor, Article._meta.db_table)
|
||||
self.assertEqual(
|
||||
set(key_columns),
|
||||
set([('reporter_id', Reporter._meta.db_table, 'id'),
|
||||
('response_to_id', Article._meta.db_table, 'id')]))
|
||||
{('reporter_id', Reporter._meta.db_table, 'id'),
|
||||
('response_to_id', Article._meta.db_table, 'id')})
|
||||
|
||||
def test_get_primary_key_column(self):
|
||||
with connection.cursor() as cursor:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue