Merge pull request #12450 from iantropov/master

Fix bug, when ':dependent => :destroy' violates foreign key constraints

Conflicts:
	activerecord/CHANGELOG.md
	activerecord/lib/active_record/associations/builder/association.rb
	activerecord/lib/active_record/associations/builder/has_one.rb

Conflicts:
	activerecord/CHANGELOG.md