On Wed, Mar 2, 2011 at 1:46 PM, Colin Law <[email protected]> wrote:
> On 2 March 2011 17:54, David Kahn <[email protected]> wrote: > > ... > > *BUT* some piece of code is still deciding that I have 'taxis' and not > > 'taxes' --- spec still failing: > > > > 1) AccountSubcode > > Failure/Error: it { should have_many(:xp_jurisdiction_taxes) } > > NameError: > > uninitialized constant AccountSubcode::XpJurisdictionTaxis > > # ./spec/models/account_subcode_spec.rb:16:in `block (2 levels) in > <top > > (required)>' > > It seems as if shoulda is not picking up the inflections for some > reason. I don't use shoulda, can you output debug during its > execution? Is so what happens if you output > "xp_jurisdiction_taxes".singularize and "taxes".singularize? > Good question... and rails gets it right: ruby-1.9.2-p136 :004 > 'xp_jurisdiction_taxes'.singularize => "xp_jurisdiction_tax" When I have a chance will start looking at the shoulda source... > > > > 2) XpJurisdictionState > > Failure/Error: it { should have_many(:xp_jurisdiction_taxes) } > > NameError: > > uninitialized constant XpJurisdictionState::XpJurisdictionTaxis > > # ./spec/models/xp_jurisdiction_state_spec.rb:4:in `block (2 levels) > in > > <top (required)>' > > > > So... all the important tests are failing but not my shoulda checks on my > > I presume you meant passing rather than failing :) > Oh, yeah.... everything else *is* working > > Colin > > -- > 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. > > -- 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.

