Skip to content

Instantly share code, notes, and snippets.

@daveworth
Created December 13, 2011 16:36
Show Gist options
  • Select an option

  • Save daveworth/1472820 to your computer and use it in GitHub Desktop.

Select an option

Save daveworth/1472820 to your computer and use it in GitHub Desktop.
Now with external attributes
require 'spec_helper'
describe AnotherModel do
it "should process a fixture" do
ap expected = AnotherModel.human_attribute_name('expected_countries')
index = 0
country_fixture.each_line do |line|
line.should match expected[index]
index += 1
end
end
# ... snip ...
# auxiliary functions still need to be here.
end
en:
activerecord:
attributes:
another_model:
expected_countries: [Zimbabwe, Tibet, Equador]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment