rails/activerecord/test/fixtures/pirates.yml
Prathamesh Sonpatki 8da936a5d3 Fix lookup of fixtures with non-string label
- Fixtures with non-string labels such as integers should be accessed
   using integer label as key. For eg. pirates(1) or pirates(42).
 - But this results in NotFound error because the label is converted into string before
   looking up into the fixtures hash.
 - After this commit, the label is converted into string only if its a
   symbol.
 - This issue was fount out while adding a test case for
   https://github.com/rails/rails/commit/7b910917.
2015-01-06 17:15:39 +05:30

16 lines
273 B
YAML

blackbeard:
catchphrase: "Yar."
parrot: george
redbeard:
catchphrase: "Avast!"
parrot: louis
created_on: "<%= 2.weeks.ago.to_s(:db) %>"
updated_on: "<%= 2.weeks.ago.to_s(:db) %>"
mark:
catchphrase: "X $LABELs the spot!"
1:
catchphrase: "#$LABEL pirate!"