I have been struggling to get fixtures to work here with no success.
They just Do Not Work For Me ™.
I have created a model named Headline with the `generate’ script and
modified the test/fixtumes/headlines.yml as follows
happened_at: 2005-01-01 00:00:00
This is the CD reissue of the 1974 album and second solo
by Raul Seixas, an important figure of Brazilian rock.
critic of establishment, he pardodies several figures of
Brazilian showbiz in the rocking “Super-Heróis.”
more fixtures here
My database table has columns named id, author, title, happened_at and
description as expected. My headline_test file is as follows
class HeadlineTest < Test::Unit::TestCase
def test_fixture h = @headlines['gita'] puts h.title end
When I call the test with `ruby test/unit/headline_test’, I get the
NoMethodError: You have a nil object when you didn’t expect it!
You might have expected an instance of Array.
The error occured while evaluating nil.
The call to the `fixtures’ methods is supposed to initalize the
@headlines instance variable, isn’t it? I can’t see where is my