Opened 15 years ago

Closed 15 years ago

Last modified 13 years ago

#13108 closed (fixed)

contrib.auth test fails due to duplicate user

Reported by: Ben Owned by: nobody
Component: contrib.auth Version: dev
Severity: 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

In django.contrib.auth.tests.auth_backends.py we have (line 153)
self.user2 = User.objects.create_user('test2', 'test2@example.com', 'test')
In django.contrib.auth.tests.forms.py we have (line 224)
>>> user = User.objects.create_user('test2', 'tesT@EXAMple.com', 'test')

These usernames clash and an error is raised. The attached patch simply changes the usernames in forms.py.

Attachments (1)

forms.diff (700 bytes ) - added by Ben 15 years ago.

Download all attachments as: .zip

Change History (6)

by Ben, 15 years ago

Attachment: forms.diff added

comment:1 by Ben, 15 years ago

Component: UncategorizedAuthentication
Has patch: set

comment:2 by Russell Keith-Magee, 15 years ago

milestone: 1.2
Triage Stage: UnreviewedReady for checkin

I'm guessing this problem can only be triggered with certain test ordering, because I can't force the error myself. However, it's a trivial fix, so it warrants correction.

comment:3 by Russell Keith-Magee, 15 years ago

Resolution: fixed
Status: newclosed

(In [12778]) Fixed #13108 -- Corrected an ambiguity in test data with the potential to cause test failures out of the box. Thanks to benreynwar for the report.

comment:4 by Russell Keith-Magee, 15 years ago

(In [12779]) [1.1.X] Fixed #13108 -- Corrected an ambiguity in test data with the potential to cause test failures out of the box. Thanks to benreynwar for the report.

Backport of r12778 from trunk.

comment:5 by Jacob, 13 years ago

milestone: 1.2

Milestone 1.2 deleted

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