Code

Opened 2 years ago

Closed 2 years ago

#17938 closed Bug (fixed)

Transient failure of regressiontests.servers.tests.LiveServerDatabase on oracle

Reported by: nate_b Owned by: nobody
Component: Testing framework Version: master
Severity: Normal Keywords:
Cc: Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

When running the entire test suite against oracle xe 10g, the following failure is seen:

======================================================================
FAIL: test_database_writes (regressiontests.servers.tests.LiveServerDatabase)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/nate/django/trunk/tests/regressiontests/servers/tests.py", line 215, in test_database_writes
    self.assertEquals(names, ['jane', 'robert', 'emily'])
AssertionError: Lists differ: [u'emily', u'jane', u'robert'] != ['jane', 'robert', 'emily']

First differing element 0:
emily
jane

- [u'emily', u'jane', u'robert']
+ ['jane', 'robert', 'emily']

Strangely, this does not happen when run in isolation. Inspecting the query results just shows that Oracle is returning the results unordered. The correct thing to do then would be to use order_by

Attachments (1)

17938.patch (1.0 KB) - added by nate_b 2 years ago.

Download all attachments as: .zip

Change History (4)

Changed 2 years ago by nate_b

comment:1 Changed 2 years ago by nate_b

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Severity changed from Release blocker to Normal

comment:2 Changed 2 years ago by claudep

  • Triage Stage changed from Unreviewed to Ready for checkin
  • Type changed from Uncategorized to Bug

comment:3 Changed 2 years ago by claudep

  • Resolution set to fixed
  • Status changed from new to closed

In [17869]:

Fixed #17938 -- Made explicit object ordering in LiveServerDatabase test assertion. Thanks Nate Bragg for the patch.

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.