aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/CHANGELOG.md
diff options
context:
space:
mode:
authorGeorge Claghorn <george.claghorn@gmail.com>2015-05-15 23:27:41 -0400
committerGeorge Claghorn <george.claghorn@gmail.com>2015-05-27 21:48:58 -0400
commit908cfef6e2f2c888e02b89fc74888786efda2a45 (patch)
tree9674dec4166259eb74133c8a845bf04862db3050 /activerecord/CHANGELOG.md
parent27fdf4591d06d11728649714bdaf0a006908861b (diff)
downloadrails-908cfef6e2f2c888e02b89fc74888786efda2a45.tar.gz
rails-908cfef6e2f2c888e02b89fc74888786efda2a45.tar.bz2
rails-908cfef6e2f2c888e02b89fc74888786efda2a45.zip
Resolve enums in test fixtures
Currently, values for columns backing Active Record enums must be specified as integers in test fixtures: awdr: title: "Agile Web Development with Rails" status: 2 rfr: title: "Ruby for Rails" status: <%= Book.statuses[:proposed] %> This is potentially confusing, since enum values are typically specified as symbols or strings in application code. To resolve the confusion, this change permits the use of symbols or strings to specify enum values: awdr: status: :published It is compatible with fixtures that specify enum values as integers.
Diffstat (limited to 'activerecord/CHANGELOG.md')
-rw-r--r--activerecord/CHANGELOG.md9
1 files changed, 9 insertions, 0 deletions
diff --git a/activerecord/CHANGELOG.md b/activerecord/CHANGELOG.md
index 5d75d9bc31..86901b1131 100644
--- a/activerecord/CHANGELOG.md
+++ b/activerecord/CHANGELOG.md
@@ -1,3 +1,12 @@
+* Allow the use of symbols or strings to specify enum values in test
+ fixtures:
+
+ awdr:
+ title: "Agile Web Development with Rails"
+ status: :proposed
+
+ *George Claghorn*
+
* Include stored procedures and function on the MySQL structure dump.
*Jonathan Worek*