File tree Expand file tree Collapse file tree 1 file changed +8
-9
lines changed Expand file tree Collapse file tree 1 file changed +8
-9
lines changed Original file line number Diff line number Diff line change @@ -34,15 +34,14 @@ def test_table_names(self):
34
34
)
35
35
36
36
def test_django_table_names (self ):
37
- with connection .cursor () as cursor :
38
- cursor .execute ("CREATE TABLE django_ixn_test_table (id INTEGER);" )
39
- tl = connection .introspection .django_table_names ()
40
- cursor .execute ("DROP TABLE django_ixn_test_table;" )
41
- self .assertNotIn (
42
- "django_ixn_test_table" ,
43
- tl ,
44
- "django_table_names() returned a non-Django table" ,
45
- )
37
+ connection .database .create_collection ("django_ixn_test_table" )
38
+ tl = connection .introspection .django_table_names ()
39
+ connection .database ["django_ixn_test_table" ].drop ()
40
+ self .assertNotIn (
41
+ "django_ixn_test_table" ,
42
+ tl ,
43
+ "django_table_names() returned a non-Django table" ,
44
+ )
46
45
47
46
def test_django_table_names_retval_type (self ):
48
47
# Table name is a list #15216
You can’t perform that action at this time.
0 commit comments