Kai Rubarth wrote in post #960590:> I was surprised to find out that Fixtures are ActiveRecord based, even
> in Rails 3.0 where integration of other ORMs has become easier.
> Although I am using factories like Mechanist and FactoryGirl, I still
> believe that fixtures can be useful: They provide a concise, language
> independent, easily readable and shareable way to express test data.
YAML files are useful for that, but Rails'' fixtures are the wrong way
to
deal with them. I suppose you could read factory data from YAML, and
get the advantages of YAML without the brokenness of fixtures.
But anyway, why should your test data be language-independent? Where''s
the value in that at the level at which you''re using factories? The
only level where that would have any advantage, it seems to me, is the
level at which you''re (hopefully) already using Cucumber stories (and
examples, and maybe Pickle), which already give you the language
independence you need.
>
> So I was wondering if there is any plan to remove that ActiveRecord
> tie and instead base fixtures on ActiveModel. Or should fixtures be
> generally regarded as a relict that is soon going to be removed from
> Rails?
I believe they should be regarded that way. Fixtures are better than
nothing at all, but that''s about it. They are misguided and (IMHO)
dangerous. I believe they should be removed from Rails, and I think
*not* removing them in Rails 3 was a missed opportunity.
Best,
--
Marnen Laibow-Koser
http://www.marnen.org
marnen-sbuyVjPbboAdnm+yROfE0A@public.gmane.org
--
Posted via http://www.ruby-forum.com/.
--
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Talk" group.
To post to this group, send email to
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en.