Warning: Can't synchronize with repository "(default)" (Unsupported version control system "svn": No module named svn). Look in the Trac log for more information.

Ticket #1891 (closed defect: fixed)

Opened 11 years ago

Last modified 10 years ago

[PATCH]: Change testutil to drop DROP...CASCADE when dropping tables

Reported by: mw44118 Owned by: kskuhlman
Priority: normal Milestone: 1.1
Component: TurboGears Version: 1.0.4.4
Severity: minor Keywords: needs tests
Cc:

Description

I've got a data model where two tables refer to each other. testutil bombs because when it drops the tables, postgres fusses that it needs the CASCADE keyword.

So this insignificant patch adds cascade=True.

Attachments

my_patch.diff Download (525 bytes) - added by mw44118 11 years ago.

Change History

Changed 11 years ago by mw44118

comment:1 Changed 11 years ago by kskuhlman

  • Owner changed from anonymous to kskuhlman

comment:2 Changed 11 years ago by Chris Arndt

Maybe there should also be a source code comment added that explains why this parameter is present.

comment:3 Changed 11 years ago by Chris Arndt

Also a test is missing that demonstrates that this indeed correctly drops cross-referencing tables.

comment:4 Changed 11 years ago by kskuhlman

  • Severity changed from normal to minor
  • Milestone set to 1.5

Committed in r5196 for 1.1 & 1.5. Leaving ticket open due to Chris' concerns re: specific test.

comment:5 Changed 11 years ago by faide

  • Milestone changed from 1.5 to 1.1

comment:6 Changed 11 years ago by Chris Arndt

  • Keywords needs tests added

comment:7 Changed 11 years ago by Chris Arndt

  • Milestone changed from 1.1 to 1.1 beta 2

comment:8 Changed 11 years ago by faide

someone wants to write those tests ?

comment:9 Changed 10 years ago by mw44118

I don't think we need a test for something this trivial. Five minutes of human review should be sufficient.

comment:10 Changed 10 years ago by faide

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

since this would be a test for testutils you are exempted :)

comment:11 Changed 10 years ago by Chris Arndt

  • Milestone changed from 1.1b4 to 1.1
Note: See TracTickets for help on using tickets.