Code

Opened 14 months ago

Closed 10 months ago

Last modified 10 months ago

#19940 closed Bug (fixed)

Regression: setup_databases in test.simple.DjangoTestSuiteRunner doesn't handle aliases for 'default'

Reported by: simonpercivall Owned by: nobody
Component: Testing framework Version: 1.5-rc-1
Severity: Normal Keywords:
Cc: timograham@… Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: yes
Easy pickings: no UI/UX: no

Description

Regression caused by 17954.

If there's an alias for the 'default' db, they both get 'default' as test dependency, which causes dependency_ordered() to raise ImproperlyConfigured.

Attachments (2)

setup_databases.patch (2.3 KB) - added by simonpercivall 10 months ago.
setup_databases_head.patch (2.2 KB) - added by simonpercivall 10 months ago.

Download all attachments as: .zip

Change History (11)

comment:1 Changed 14 months ago by simonpercivall

  • Component changed from Uncategorized to Testing framework
  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Type changed from Uncategorized to Bug

comment:2 Changed 14 months ago by jacob

  • Triage Stage changed from Unreviewed to Accepted

comment:3 Changed 10 months ago by timo

  • Cc timograham@… added
  • Needs tests set
  • Patch needs improvement set

Patch no longer applies cleanly and needs a test.

Changed 10 months ago by simonpercivall

comment:4 Changed 10 months ago by simonpercivall

New patch that applies on stable/1.5.x, and test case.

comment:5 Changed 10 months ago by timo

  • Needs tests unset

Thanks, I'm not sure if this will be backported to 1.5.x though. Could you provide a patch against master (some code/files have been moved around there)?

Changed 10 months ago by simonpercivall

comment:6 Changed 10 months ago by simonpercivall

I added a patch against master. I do think it'd it's a pity though if it's not applied to 1.5.x. It's an obvious regression, it's non-workaroundable, and it affects only the test framework.

comment:7 Changed 10 months ago by Tim Graham <timograham@…>

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

In 2cbd579efe2d646814bd6cb7aca8bd43a96f14ae:

Fixed #19940 -- Made test.runner.setup_databases properly handle aliases for default db.

Thanks simonpercivall.

comment:8 Changed 10 months ago by Tim Graham <timograham@…>

In d14db25feec73690b1cd52b3f8b83e3e38deb23b:

[1.6.x] Fixed #19940 -- Made test.runner.setup_databases properly handle aliases for default db.

Thanks simonpercivall.

Backport of 2cbd579efe from master.

comment:9 Changed 10 months ago by Tim Graham <timograham@…>

In 95aa2182b7878c1c64b1812b02caa38060ebcab4:

[1.5.x] Fixed #19940 -- Made test.runner.setup_databases properly handle aliases for defau

Thanks simonpercivall.

Backport of 2cbd579efe from master.

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.