<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -27,7 +27,7 @@ in your test\_helper.rb (or spec\_helper.rb).
     
     Comment.blueprint do
       post
-      author { Faker::Name.name }  # Use the Faker gem to generate a name.
+      author { Sham.name }  # Use the Sham to generate a name. See docs below.
       body   &quot;Lorem ipsum dolor sit amet&quot;
     end
 
@@ -46,6 +46,39 @@ In your tests, you can now do things like:
     @post = Post.make
     3.times { Comment.make(:post =&gt; @post) }
     
+Sham
+====
+
+Sham lets you generate random but repeatable unique values for blueprints.
+
+For example, you could put this in your blueprints.rb:
+    
+    # Tell sham how to generate a random name (using the Faker gem in this case).
+    Sham.name { Faker::Name.name }
+    
+    Comment.blueprint do
+      author { Sham.name } # Set the author's name to a random name.
+    end
+    
+Sham takes the random names generated by Faker and ensures two things:
+
+1. You will get the same sequence of names every time you run a test.
+2. You won't get the same name twice.
+
+To ensure that you get repeatable values, you have to reset Sham before every test or spec.
+
+If you're using Test::Unit, add this to your test_helper.rb:
+
+    class Test::Unit::TestCase
+      setup { Sham.reset }
+    end
+
+If you're using RSpec, add this to your spec_helper.rb:
+
+    Spec::Runner.configure do |config|
+      config.before(:each) { Sham.reset }
+    end
+    
 Install
 =======
 </diff>
      <filename>README.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -1,7 +1,3 @@
-require 'active_support'
-require 'active_support/test_case'
-require 'test/unit'
-
 module Sham
   @@values     = {}
   @@offsets    = {}
@@ -51,16 +47,3 @@ private
     result
   end
 end
-
-
-module Test #:nodoc:
-  module Unit #:nodoc:
-    class TestCase #:nodoc:
-      setup :reset_sham
-      
-      def self.reset_sham
-        Sham.reset
-      end
-    end
-  end
-end</diff>
      <filename>lib/sham.rb</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>b71be837b12bfe1a2bbb25aa1711861ac1e8a245</id>
    </parent>
  </parents>
  <author>
    <name>Pete Yandell</name>
    <email>pete@notahat.com</email>
  </author>
  <url>http://github.com/technoweenie/machinist/commit/8b08de35e178c11d461cf5ef4f65ca00c23e1ca1</url>
  <id>8b08de35e178c11d461cf5ef4f65ca00c23e1ca1</id>
  <committed-date>2008-10-20T21:53:35-07:00</committed-date>
  <authored-date>2008-10-20T21:53:35-07:00</authored-date>
  <message>Added some rough docs for Sham, and got rid of the failed attempt to have Test::Unit automatically reset Sham before each test.</message>
  <tree>e158b0974b7950915b6097623cc0480553c4930e</tree>
  <committer>
    <name>Pete Yandell</name>
    <email>pete@notahat.com</email>
  </committer>
</commit>
