Bugfix circular reference while saving has_one relationship
Test for circular reference while saving has_one relationship
Add order to tests that rely on db ordering, to fix failing tests on pg

Also skip persistente tests related to UPDATE + ORDER BY for postgresql

PostgreSQL does not support updates with order by, and these tests are
failing randomly depending on the fixture loading order now.

Conflicts:

	activerecord/test/cases/associations/join_model_test.rb
	activerecord/test/cases/associations/nested_through_associations_test.rb
	activerecord/test/cases/clone_test.rb
	activerecord/test/cases/dup_test.rb
	activerecord/test/cases/relations_test.rb
	activerecord/test/cases/yaml_serialization_test.rb
Fix more failing tests related to ruby 1.8.7 p358 version change
Merge pull request #5565 from carlosantoniodasilva/fix-build-3-0

Fix build for branch 3-0-stable
Build fix for form_options_helper_test.rb ruby-1.8.7
Fix AV::FixtureResolver and rjs tests with random order errors

Due to the hash ordering changes on Ruby 1.8.7-p358.
Merge pull request #2621 from icco/master

Issue with schema dump
Merge pull request #5600 from carlosantoniodasilva/fix-build-3-0

Fix build for branch 3-0-stable - failing in ruby 1.8.8-p358
Silence warnings here, only setting Encoding.default_external for testing.
Use helper method here.
load the encoding converter to work around [ruby-core:41556] when switching encodings
Fix broken encoding test
Avoid inspecting the whole route set, closes #1525
Merge pull request #5613 from carlosantoniodasilva/fix-build-3-0-193

Fix build for branch 3-0-stable - Ruby 1.9.3
Address an error for test_has_many_through_polymorphic_has_one
with Oracle for the 3-0-stable branch
Merge pull request #5655 from yahonda/address_ora_00918_with_oracle_for_3_0

Address an error for test_has_many_through_polymorphic_has_one with Oracle
Fix failing ARes test due to hash keys ordering
Merge pull request #5659 from carlosantoniodasilva/fix-build-3-0

Fix build for branch 3-0-stable - ARes and ordered hash keys
Merge pull request #5044 from dracco/3-0-stable

Backport Bugfix: Stack Overflow (3-0-stable)