Forum: Ruby on Rails Instance variable shortcuts to fixture data are not working?

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
Sergei S. (Guest)
on 2006-03-21 19:39

I am following the Agile Web D. with Rails book and it looks
like either book is wrong or edge rails are broken.

I am trying to access fixture data through instance shortcuts. I.e.
customers.yml through @customers and it is not assigned.

Anybody knows why?

Sergei S. (Guest)
on 2006-03-21 19:39
If you have the book, look at pages 148-149 to see what I am talking
Oliver L. (Guest)
on 2006-03-21 19:42
(Received via mailing list)
The way the fixtures in test changed sometime, for speed improvements.

They should now be accessed as customers(:id), I think.

Or there is an option you can change in the test_helper.rb
Sergei S. (Guest)
on 2006-03-21 20:59
Thank you Oliver, you are right.
This topic is locked and can not be replied to.