Forum: Ruby on Rails unit_tests and deleting from the database

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
Oom Tuinstoel (Guest)
on 2006-03-17 20:10
I get errors when running rake test_units:

ActiveRecord::StatementInvalid: Mysql::Error: #23000Cannot delete or
update a pa
rent row: a foreign key constraint fails (`overblijf_tst/groups`,
_groups_locations` FOREIGN KEY (`location_id`) REFERENCES `locations`
(`id`)): D
ELETE FROM locations

Any pointers??
This topic is locked and can not be replied to.