How do you load fixtures from specs as you would test? eg. rake db:fixtures:load RAILS_ENV=development -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/rspec-users/attachments/20080131/38c3b0ab/attachment.html
Do you want to load them in your controller? You can put class MyController fixtures :fixturename end -Corey On Jan 31, 2008 5:52 PM, Andrew WC Brown <omen.king at gmail.com> wrote:> How do you load fixtures from specs as you would test? > > eg. rake db:fixtures:load RAILS_ENV=development > > _______________________________________________ > rspec-users mailing list > rspec-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-users >-- http://www.coreyhaines.com The Internet''s Premiere source of information about Corey Haines -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/rspec-users/attachments/20080131/1373012d/attachment.html
no, just database On Jan 31, 2008 6:56 PM, Corey Haines <coreyhaines at gmail.com> wrote:> Do you want to load them in your controller? You can put > > class MyController > fixtures :fixturename > > end > > > -Corey > > On Jan 31, 2008 5:52 PM, Andrew WC Brown <omen.king at gmail.com> wrote: > > > How do you load fixtures from specs as you would test? > > > > eg. rake db:fixtures:load RAILS_ENV=development > > > > _______________________________________________ > > rspec-users mailing list > > rspec-users at rubyforge.org > > http://rubyforge.org/mailman/listinfo/rspec-users > > > > > > -- > http://www.coreyhaines.com > The Internet''s Premiere source of information about Corey Haines > _______________________________________________ > rspec-users mailing list > rspec-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-users >-------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/rspec-users/attachments/20080131/4583e5c9/attachment.html
rake db:fixtures:load doesn''t work? On Jan 31, 2008 6:57 PM, Andrew WC Brown <omen.king at gmail.com> wrote:> no, just database > > > On Jan 31, 2008 6:56 PM, Corey Haines <coreyhaines at gmail.com> wrote: > > > Do you want to load them in your controller? You can put > > > > class MyController > > fixtures :fixturename > > > > end > > > > > > -Corey > > > > On Jan 31, 2008 5:52 PM, Andrew WC Brown <omen.king at gmail.com> wrote: > > > > > How do you load fixtures from specs as you would test? > > > > > > eg. rake db:fixtures:load RAILS_ENV=development > > > > > > _______________________________________________ > > > rspec-users mailing list > > > rspec-users at rubyforge.org > > > http://rubyforge.org/mailman/listinfo/rspec-users > > > > > > > > > > > -- > > http://www.coreyhaines.com > > The Internet''s Premiere source of information about Corey Haines > > _______________________________________________ > > rspec-users mailing list > > rspec-users at rubyforge.org > > http://rubyforge.org/mailman/listinfo/rspec-users > > > > > _______________________________________________ > rspec-users mailing list > rspec-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-users >-- http://www.coreyhaines.com The Internet''s Premiere source of information about Corey Haines -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/rspec-users/attachments/20080131/5447d6fd/attachment-0001.html
loads the test fixtures, instead of the spec fixtures directory.Does it work for you? On Jan 31, 2008 7:03 PM, Corey Haines <coreyhaines at gmail.com> wrote:> rake db:fixtures:load doesn''t work? > > > On Jan 31, 2008 6:57 PM, Andrew WC Brown <omen.king at gmail.com> wrote: > > > no, just database > > > > > > On Jan 31, 2008 6:56 PM, Corey Haines <coreyhaines at gmail.com> wrote: > > > > > Do you want to load them in your controller? You can put > > > > > > class MyController > > > fixtures :fixturename > > > > > > end > > > > > > > > > -Corey > > > > > > On Jan 31, 2008 5:52 PM, Andrew WC Brown <omen.king at gmail.com> wrote: > > > > > > > How do you load fixtures from specs as you would test? > > > > > > > > eg. rake db:fixtures:load RAILS_ENV=development > > > > > > > > _______________________________________________ > > > > rspec-users mailing list > > > > rspec-users at rubyforge.org > > > > http://rubyforge.org/mailman/listinfo/rspec-users > > > > > > > > > > > > > > > > -- > > > http://www.coreyhaines.com > > > The Internet''s Premiere source of information about Corey Haines > > > _______________________________________________ > > > rspec-users mailing list > > > rspec-users at rubyforge.org > > > http://rubyforge.org/mailman/listinfo/rspec-users > > > > > > > > > _______________________________________________ > > rspec-users mailing list > > rspec-users at rubyforge.org > > http://rubyforge.org/mailman/listinfo/rspec-users > > > > > > -- > http://www.coreyhaines.com > The Internet''s Premiere source of information about Corey Haines > > _______________________________________________ > rspec-users mailing list > rspec-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-users >-------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/rspec-users/attachments/20080131/62c15ae2/attachment.html
try this instead: rake spec:db:fixtures:load HTH 2008/2/1, Andrew WC Brown <omen.king at gmail.com>:> > loads the test fixtures, instead of the spec fixtures directory.Does it > work for you? > > On Jan 31, 2008 7:03 PM, Corey Haines <coreyhaines at gmail.com> wrote: > > > rake db:fixtures:load doesn''t work? > > > > > > On Jan 31, 2008 6:57 PM, Andrew WC Brown <omen.king at gmail.com> wrote: > > > > > no, just database > > > > > > > > > On Jan 31, 2008 6:56 PM, Corey Haines <coreyhaines at gmail.com> wrote: > > > > > > > Do you want to load them in your controller? You can put > > > > > > > > class MyController > > > > fixtures :fixturename > > > > > > > > end > > > > > > > > > > > > -Corey > > > > > > > > On Jan 31, 2008 5:52 PM, Andrew WC Brown <omen.king at gmail.com> > > > > wrote: > > > > > > > > > How do you load fixtures from specs as you would test? > > > > > > > > > > eg. rake db:fixtures:load RAILS_ENV=development > > > > > > > > > > _______________________________________________ > > > > > rspec-users mailing list > > > > > rspec-users at rubyforge.org > > > > > http://rubyforge.org/mailman/listinfo/rspec-users > > > > > > > > > > > > > > > > > > > > > -- > > > > http://www.coreyhaines.com > > > > The Internet''s Premiere source of information about Corey Haines > > > > _______________________________________________ > > > > rspec-users mailing list > > > > rspec-users at rubyforge.org > > > > http://rubyforge.org/mailman/listinfo/rspec-users > > > > > > > > > > > > > _______________________________________________ > > > rspec-users mailing list > > > rspec-users at rubyforge.org > > > http://rubyforge.org/mailman/listinfo/rspec-users > > > > > > > > > > > -- > > http://www.coreyhaines.com > > The Internet''s Premiere source of information about Corey Haines > > > > _______________________________________________ > > rspec-users mailing list > > rspec-users at rubyforge.org > > http://rubyforge.org/mailman/listinfo/rspec-users > > > > > _______________________________________________ > rspec-users mailing list > rspec-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-users >-- Bekk Open Source http://boss.bekk.no -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/rspec-users/attachments/20080201/b977f819/attachment.html
I see, sorry. I misunderstood. This is good to know. -Corey On Feb 1, 2008 5:03 AM, Stefan Magnus Landr? <stefan.landro at gmail.com> wrote:> try this instead: rake spec:db:fixtures:load > > HTH > > 2008/2/1, Andrew WC Brown <omen.king at gmail.com>: > > > loads the test fixtures, instead of the spec fixtures directory.Does it > > work for you? > > > > On Jan 31, 2008 7:03 PM, Corey Haines <coreyhaines at gmail.com> wrote: > > > > > rake db:fixtures:load doesn''t work? > > > > > > > > > On Jan 31, 2008 6:57 PM, Andrew WC Brown <omen.king at gmail.com> wrote: > > > > > > > no, just database > > > > > > > > > > > > On Jan 31, 2008 6:56 PM, Corey Haines <coreyhaines at gmail.com> wrote: > > > > > > > > > Do you want to load them in your controller? You can put > > > > > > > > > > class MyController > > > > > fixtures :fixturename > > > > > > > > > > end > > > > > > > > > > > > > > > -Corey > > > > > > > > > > On Jan 31, 2008 5:52 PM, Andrew WC Brown <omen.king at gmail.com> > > > > > wrote: > > > > > > > > > > > How do you load fixtures from specs as you would test? > > > > > > > > > > > > eg. rake db:fixtures:load RAILS_ENV=development > > > > > > > > > > > > _______________________________________________ > > > > > > rspec-users mailing list > > > > > > rspec-users at rubyforge.org > > > > > > http://rubyforge.org/mailman/listinfo/rspec-users > > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > > http://www.coreyhaines.com > > > > > The Internet''s Premiere source of information about Corey Haines > > > > > _______________________________________________ > > > > > rspec-users mailing list > > > > > rspec-users at rubyforge.org > > > > > http://rubyforge.org/mailman/listinfo/rspec-users > > > > > > > > > > > > > > > > > _______________________________________________ > > > > rspec-users mailing list > > > > rspec-users at rubyforge.org > > > > http://rubyforge.org/mailman/listinfo/rspec-users > > > > > > > > > > > > > > > > -- > > > http://www.coreyhaines.com > > > The Internet''s Premiere source of information about Corey Haines > > > > > > _______________________________________________ > > > rspec-users mailing list > > > rspec-users at rubyforge.org > > > http://rubyforge.org/mailman/listinfo/rspec-users > > > > > > > > > _______________________________________________ > > rspec-users mailing list > > rspec-users at rubyforge.org > > http://rubyforge.org/mailman/listinfo/rspec-users > > > > > > -- > Bekk Open Source > http://boss.bekk.no > _______________________________________________ > rspec-users mailing list > rspec-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-users >-- http://www.coreyhaines.com The Internet''s Premiere source of information about Corey Haines -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/rspec-users/attachments/20080202/7b6937f9/attachment.html