<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -113,6 +113,7 @@ module Exegesis
       # update the attributes in the model using writers. If no writer is defined for a given
       # key it will raise NoMethodError
       def update_attributes hash={}
+        hash.delete('class')
         hash.each do |key, value| 
           self.send(&quot;#{key}=&quot;, value)
         end</diff>
      <filename>lib/exegesis/model.rb</filename>
    </modified>
    <modified>
      <diff>@@ -295,7 +295,7 @@ describe Exegesis::Model do
       expect { @obj.read_only.must_equal 'bee' } 
     end
     
-    describe &quot;update&quot; do
+    describe &quot;update_attributes&quot; do
       describe &quot;with a writer&quot; do
         before do
           @obj.update_attributes(:foo =&gt; 'foo')
@@ -307,6 +307,14 @@ describe Exegesis::Model do
       describe &quot;without a writer&quot; do
         expect { lambda{@obj.update_attributes({:read_only =&gt; 'bee'})}.must_raise NoMethodError }
       end
+      
+      describe &quot;with a 'class' key&quot; do
+        before do
+          @obj.update_attributes('class' =&gt; 'Foo')
+        end
+        
+        expect { @obj['class'].must_equal 'ExposeTestModel' }
+      end
     end
   end
   </diff>
      <filename>test/model_test.rb</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>c77eaea48f5152d2ba9c9fe2c704981dad8fc6b2</id>
    </parent>
  </parents>
  <author>
    <name>Matt Lyon</name>
    <email>matt@flowerpowered.com</email>
  </author>
  <url>http://github.com/mattly/exegesis/commit/18abe37e2465de15dd3abc2d488a17ea7a2258ec</url>
  <id>18abe37e2465de15dd3abc2d488a17ea7a2258ec</id>
  <committed-date>2009-05-03T22:23:10-07:00</committed-date>
  <authored-date>2009-05-03T22:23:10-07:00</authored-date>
  <message>filter out a 'class' key on update_attributes, instead of requiring the client to filter it for us</message>
  <tree>e70135f850e1ab5f187b2b1f25480c787aa3bd87</tree>
  <committer>
    <name>Matt Lyon</name>
    <email>matt@flowerpowered.com</email>
  </committer>
</commit>
