Opened 11 years ago

Closed 11 years ago

Last modified 11 years ago

#20905 closed Bug (fixed)

Test failure on Oracle: test_child_link_prefetch

Reported by: Shai Berger Owned by: nobody
Component: Database layer (models, ORM) Version: 1.4
Severity: Normal Keywords: oracle
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: yes UI/UX: no

Description

Running tests on update stable/1.4.x

FAIL: test_child_link_prefetch (modeltests.prefetch_related.tests.MultiTableInheritanceTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/django/django/django/test/utils.py", line 215, in inner
    return test_func(*args, **kwargs)
  File "/home/django/django/tests/modeltests/prefetch_related/tests.py", line 367, in test_child_link_prefetch
    self.assertIn('authorwithage', connection.queries[-1]['sql'])
AssertionError: 'authorwithage' not found in 'SELECT "PREFETCH_RELATED_AUTHOR"."ID", "PREFETCH_RELATED_AUTHOR"."NAME", "PREFETCH_RELATED_AUTHOR"."FIRST_BOOK_ID", "PREFETCH_RELATED_AUTHORWITHAGE"."AUTHOR_ID", "PREFETCH_RELATED_AUTHORWITHAGE"."AGE" FROM "PREFETCH_RELATED_AUTHORWITHAGE" INNER JOIN "PREFETCH_RELATED_AUTHOR" ON ("PREFETCH_RELATED_AUTHORWITHAGE"."AUTHOR_ID" = "PREFETCH_RELATED_AUTHOR"."ID") WHERE "PREFETCH_RELATED_AUTHORWITHAGE"."AUTHOR_ID" IN (:arg0, :arg1, :arg2) ORDER BY "PREFETCH_RELATED_AUTHORWITHAGE"."AUTHOR_ID" ASC'

Test fails because of Oracle's letter-case issues.

Change History (2)

comment:1 by Tim Graham <timograham@…>, 11 years ago

Resolution: fixed
Status: newclosed

In bf611f14ec13312aa822beec72c63bd04950613c:

[1.4.x] Fixed #20905 -- Fixed an Oracle-specific test case failure

Made a test checking ORM-generated query string case-insensitive.

Backport of ee0a7c741e from master

comment:2 by Shai Berger, 11 years ago

Thanks, Tim!

Note: See TracTickets for help on using tickets.
Back to Top