YAML Cookbook 3

Posted by Bob Silva Fri, 30 Jun 2006 07:18:09 GMT

While researching what some of the YAML syntax was doing in Ben Bleything's article on DRY'ing up your database config, I ran across the YAML Cookbook. I've only ever used YAML for my database.yml and test fixtures, so I was really surprised to see the power YAML affords the Ruby programmer. Check it out, you will find a few things useful in your fixtures and I'm sure other ideas on it's use will come to you as you see how powerful it is.
Comments

Leave a response

  1. jean about 1 hour later:
    I tried to use references to do some DRY in fixtures, and quickly abandonned it : ref: &ref name: test user role: user joe_user: uid: 0 mail: joe@joe.com jack@jack.com joe@joe.com name: test_user role: user jack_user: jack@jack.com If you have had success in using the : * syntax to do DRY in fixtures would you ming posting a quick recipe as a future blog post ? thanks
  2. jean about 1 hour later:
    I tried to use references to do some DRY in fixtures, and quickly abandonned it : ref: &ref name: test user role: user joe_user: uid: 0 mail: joe@joe.com jack@jack.com joe@joe.com name: test_user role: user jack_user: jack@jack.com If you have had success in using the : * syntax to do DRY in fixtures would you ming posting a quick recipe as a future blog post ? thanks
  3. Power 25 days later:
    Cheese is where the home is.
Comments