Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
これはかなり単純なことですが、Rails 3.2 の一括割り当て保護はデフォルトで有効になっているため、一括割り当てによって保護された属性を設定しようとしたときに、開発またはテストで Rails に例外を発生させる方法はありますか?
development.rb では、デフォルトで以下がコメントアウトされています。コメントを外します。
config.active_record.mass_assignment_sanitizer = :strict