<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -1,31 +1,41 @@
-= factory_girl
+h1. factory_girl
 
-  written by Joe Ferris &lt;jferris@thoughtbot.com&gt;
-  thanks to Tammer Saleh, Dan Croak, and Jon Yurek of thoughtbot, inc.
-  Copyright 2008 Joe Ferris and thoughtbot, inc.
+Written by &quot;Joe Ferris&quot;:mailto:jferris@thoughtbot.com.
 
-== Defining factories
+Thanks to Tammer Saleh, Dan Croak, and Jon Yurek of thoughtbot, inc.
 
-  # This will guess the User class
-  Factory.define :user do |u|
-    u.first_name 'John'
-    u.last_name  'Doe'
-    u.admin false
-  end
+Copyright 2008 Joe Ferris and thoughtbot, inc.
+
+h2. Download
+
+Github: &quot;Page&quot;:http://github.com/thoughtbot/factory_girl/tree/master &quot;Clone&quot;:git://github.com/thoughtbot/factory_girl.git
+
+Gem: &lt;pre&gt;gem install thoughtbot-factory_girl --source http://gems.github.com&lt;/pre&gt;
+
+h2. Defining factories
+
+&lt;pre&gt;&lt;code&gt;# This will guess the User class
+Factory.define :user do |u|
+  u.first_name 'John'
+  u.last_name  'Doe'
+  u.admin false
+end
+
+# This will use the User class (Admin would have been guessed)
+Factory.define :admin, :class =&gt; User do |u|
+  u.first_name 'Admin'
+  u.last_name  'User'
+  u.admin true
+end&lt;/code&gt;&lt;/pre&gt;
 
-  # This will use the User class (Admin would have been guessed)
-  Factory.define :admin, :class =&gt; User do |u|
-    u.first_name 'Admin'
-    u.last_name  'User'
-    u.admin true
-  end
 
 It is recommended that you create a test/factories.rb file and define your
 factories there. This file can be included from test_helper or directly from
 your test files. Don't forget:
-  require 'factory_girl'
+&lt;pre&gt;&lt;code&gt;require 'factory_girl'&lt;/code&gt;&lt;/pre&gt;
+
 
-== Lazy Attributes
+h2. Lazy Attributes
 
 Most attributes can be added using static values that are evaluated when the
 factory is defined, but some attributes (such as associations and other
@@ -33,73 +43,83 @@ attributes that must be dynamically generated) will need values assigned each
 time an instance is generated. These &quot;lazy&quot; attributes can be added by passing
 a block instead of a parameter:
 
-  Factory.define :user do |u|
-    # ...
-    u.activation_code { User.generate_activation_code }
-  end
+&lt;pre&gt;&lt;code&gt;Factory.define :user do |u|
+  # ...
+  u.activation_code { User.generate_activation_code }
+end&lt;/code&gt;&lt;/pre&gt;
 
-== Dependent Attributes
+
+h2. Dependent Attributes
 
 Some attributes may need to be generated based on the values of other
 attributes. This can be done by calling the attribute name on
 Factory::AttributeProxy, which is yielded to lazy attribute blocks:
 
-  Factory.define :user do |u|
-    u.first_name 'Joe'
-    u.last_name  'Blow'
-    u.email {|a| &quot;#{a.first_name}.#{a.last_name}@example.com&quot;.downcase }
-  end
+&lt;pre&gt;&lt;code&gt;Factory.define :user do |u|
+  u.first_name 'Joe'
+  u.last_name  'Blow'
+  u.email {|a| &quot;#{a.first_name}.#{a.last_name}@example.com&quot;.downcase }
+end
+
+Factory(:user, :last_name =&gt; 'Doe').email
+# =&gt; &quot;joe.doe@example.com&quot;&lt;/code&gt;&lt;/pre&gt;
 
-  Factory(:user, :last_name =&gt; 'Doe').email
-  # =&gt; &quot;joe.doe@example.com&quot;
 
-== Associations
+h2. Associations
 
 Associated instances can be generated by using the association method when
 defining a lazy attribute:
 
-  Factory.define :post do |p|
-    # ...
-    p.author {|author| author.association(:user, :last_name =&gt; 'Writely') }
-  end
+&lt;pre&gt;&lt;code&gt;Factory.define :post do |p|
+  # ...
+  p.author {|author| author.association(:user, :last_name =&gt; 'Writely') }
+end&lt;/code&gt;&lt;/pre&gt;
+
 
 When using the association method, the same build strategy (build, create, or attributes_for) will be used for all generated instances:
 
-  # Builds and saves a User and a Post
-  post = Factory(:post)
-  post.new_record?       # =&gt; false
-  post.author.new_record # =&gt; false
+&lt;pre&gt;&lt;code&gt;# Builds and saves a User and a Post
+post = Factory(:post)
+post.new_record?       # =&gt; false
+post.author.new_record # =&gt; false
+
+# Builds but does not save a User and a Post
+Factory.build(:post)
+post.new_record?       # =&gt; true
+post.author.new_record # =&gt; true&lt;/code&gt;&lt;/pre&gt;
 
-  # Builds but does not save a User and a Post
-  Factory.build(:post)
-  post.new_record?       # =&gt; true
-  post.author.new_record # =&gt; true
 
-== Sequences
+h2. Sequences
 
 Unique values in a specific format (for example, e-mail addresses) can be
 generated using sequences. Sequences are defined by calling Factory.sequence,
 and values in a sequence are generated by calling Factory.next:
 
-  # Defines a new sequence
-  Factory.sequence :email do |n|
-    &quot;person#{n}@example.com&quot;
-  end
+&lt;pre&gt;&lt;code&gt;# Defines a new sequence
+Factory.sequence :email do |n|
+  &quot;person#{n}@example.com&quot;
+end
+
+Factory.next :email
+# =&gt; &quot;person1@example.com&quot;
+
+Factory.next :email
+# =&gt; &quot;person2@example.com&quot;&lt;/code&gt;&lt;/pre&gt;
+
 
-  Factory.next :email
-  # =&gt; &quot;person1@example.com&quot;
+h2. Using factories
 
-  Factory.next :email
-  # =&gt; &quot;person2@example.com&quot;
+&lt;pre&gt;&lt;code&gt;# Build and save a User instance
+Factory(:user)
 
-== Using factories
+# Build a User instance and override the first_name property
+Factory.build(:user, :first_name =&gt; 'Joe')
 
-  # Build and save a User instance
-  Factory(:user)
+# Return an attributes Hash that can be used to build a User instance
+attrs = Factory.attributes_for(:user)&lt;/code&gt;&lt;/pre&gt;
 
-  # Build a User instance and override the first_name property
-  Factory.build(:user, :first_name =&gt; 'Joe')
+h2. More Information
 
-  # Return an attributes Hash that can be used to build a User instance
-  attrs = Factory.attributes_for(:user)
+&quot;Our blog&quot;:http://giantrobots.thoughtbot.com
 
+&quot;factory_girl rdoc&quot;:http://dev.thoughtbot.com/factory_girl</diff>
      <filename>README.textile</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>8354b8ddd68ba9fe351e4c01194b8be162263448</id>
    </parent>
  </parents>
  <author>
    <name>Joe Ferris</name>
    <email>jferris@thoughtbot.com</email>
  </author>
  <url>http://github.com/teem/factory_girl/commit/3cde84a1a68ea865bce8766a1a142afa80c343c0</url>
  <id>3cde84a1a68ea865bce8766a1a142afa80c343c0</id>
  <committed-date>2008-06-06T08:46:39-07:00</committed-date>
  <authored-date>2008-06-06T08:46:39-07:00</authored-date>
  <message>Converted the README to textile</message>
  <tree>658981cc4fb312fd0baa446d1af304d0815532fa</tree>
  <committer>
    <name>Joe Ferris</name>
    <email>jferris@thoughtbot.com</email>
  </committer>
</commit>
