Thanks for the response. Good point about legacy data. In fact, I’m
working on a legacy system that I’d like to start integrating Rails
Would you happen to know of resources that focus on that?
Why do I care that fixtures bypass validations? I’ve been using Agile
Development with Rails 4th Ed. to learn Rails. On page 83 it says “a
fixture is simply a specification of the initial contents of a model (or
models) under test.” I was assuming that to the degree that statement
accurate, the validations coded in the model would be run against the
loaded by the fixtures. Then, when I saw that wasn’t happening, I was
surprised to find no statements about running or not running
For example,see http://guides.rubyonrails.org/testing.html
Everything you pointed out (“the purpose of fixtures…”) makes sense.
But I can also see that it would be useful to have a rake parm that
the developer control whether or not validations are run on the
From what I’ve been reading, and one of the reasons I’m finding Rails so
appealing, is that (as DHH said) Rails is an opinionated framework and
a clear and strong stance on how to build good software. With that in
mind, I was hoping to learn the reasons behind why fixtures work the way
Thanks again for your response.