If you check this out - it's in my factories.rb file:
------
# Factories
Factory.define :article do |t|
        t.association :section # 'belongs to a section'
        t.title {|x| "#{x.section.name}Article" + Factory.next(:count) }
        ...
end

(...)

Factory.define :page do |t|
        t.title "Page#{Factory.next(:count)}"
        t.styles "styles here"
        t.body Forgery::LoremIpsum.paragraphs(5)
end

# Sequences
Factory.sequence :count do |n|
        n
end
-----

I get an error in factory for page, suggesting that I can't call
"Factory.next(:count)" in different factories.  Is this the case?  Is
there something wrong with my methodology?

I know "Factory.next(:count)" works for articles...

-- 
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 [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to