1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Fix intermittent test failures

The table is being modified in tests, without reloading the column
information on the appropriate class. This is leading to incorrect
column information in many cases.

The failures fixed by this commit can be replicated with:

    ARCONN=postgresql ruby -Itest test/cases/adapters/postgresql/hstore_test.rb --seed 21574
This commit is contained in:
Sean Griffin 2015-03-09 15:52:27 -06:00
parent 2e4a01b92c
commit 761b5541b6

View file

@ -27,6 +27,7 @@ if ActiveRecord::Base.connection.supports_extensions?
t.hstore 'settings'
end
end
Hstore.reset_column_information
@column = Hstore.columns_hash['tags']
@type = Hstore.type_for_attribute("tags")
end