huacnlee / rails-settings-cached

Global settings for your Rails application.
Other
1.06k stars 202 forks source link

Ensure defaults not overwrite persisted settings #98

Closed hovsater closed 8 years ago

hovsater commented 8 years ago

This addresses an issue with #get_all and default values. If a default value exists for key x and a value for x also exists in the database, the current implementation of #get_all will override the database value with the default value.

I also noticed that the current test suite is order dependent. Try running the test suite with rspec --order rand and things start to break in all kinds of interesting ways.