Fixed #15173 -- fixed the tests when run under pypy.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@15333 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Alex Gaynor 2011-01-27 00:00:32 +00:00
parent 7505abf95d
commit 7c0e40534b
1 changed files with 1 additions and 3 deletions

View File

@ -85,9 +85,7 @@ class DatabaseIntrospection(BaseDatabaseIntrospection):
table, column = [s.strip('"') for s in m.groups()]
cursor.execute("SELECT sql FROM sqlite_master WHERE tbl_name = %s", [table])
result = cursor.fetchone()
if not result:
continue
result = cursor.fetchall()[0]
other_table_results = result[0].strip()
li, ri = other_table_results.index('('), other_table_results.rindex(')')
other_table_results = other_table_results[li+1:ri]