<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array">
    <added>
      <filename>spec/lib/mock_adapter.rb</filename>
    </added>
  </added>
  <modified type="array">
    <modified>
      <diff>@@ -2,11 +2,11 @@ unless defined?(INITIAL_CLASSES)
   # Require the DataMapper, and a Mock Adapter.
   require 'pathname'
   require Pathname(__FILE__).dirname.expand_path + 'lib/data_mapper'
-  require __DIR__ + 'spec/mock_adapter'
+  require __DIR__ + 'spec/lib/mock_adapter'
   require 'fileutils'
 
   adapter = ENV[&quot;ADAPTER&quot;] || &quot;sqlite3&quot;
-  
+
   repository_uri = URI.parse case ENV[&quot;ADAPTER&quot;]
     when 'mysql' then &quot;mysql://localhost/data_mapper_1&quot;
     when 'postgres' then &quot;postgres://localhost/data_mapper_1&quot;
@@ -14,14 +14,14 @@ unless defined?(INITIAL_CLASSES)
   end
 
   DataMapper.setup(:default, &quot;mock://localhost&quot;)
-  
+
   # Determine log path.
   ENV['_'] =~ /(\w+)/
   log_path = __DIR__ + &quot;log/#{$1 == 'opt' ? 'spec' : $1}.log&quot;
-  
+
   FileUtils::mkdir_p(File.dirname(log_path))
   # FileUtils::rm(log_path) if File.exists?(log_path)
-  
+
   DataMapper::Logger.new(log_path, 0)
   at_exit { DataMapper.logger.close }
 </diff>
      <filename>environment.rb</filename>
    </modified>
    <modified>
      <diff>@@ -1,7 +1,7 @@
 require 'pathname'
 require Pathname(__FILE__).dirname.expand_path.parent + 'spec_helper'
 
-require __DIR__.parent.parent + 'lib/data_mapper'
+require ROOT_DIR + 'lib/data_mapper'
 
 begin
   require 'do_sqlite3'</diff>
      <filename>spec/integration/association_spec.rb</filename>
    </modified>
    <modified>
      <diff>@@ -1,17 +1,17 @@
 require 'pathname'
 require Pathname(__FILE__).dirname.expand_path.parent + 'spec_helper'
 
-require __DIR__.parent.parent + 'lib/data_mapper'
+require ROOT_DIR + 'lib/data_mapper'
 
 begin
   require 'do_mysql'
 
   DataMapper.setup(:mysql, &quot;mysql://localhost/dm_integration_test&quot;)
-  
+
 rescue LoadError =&gt; e
   describe 'do_mysql' do
     it 'should be required' do
       fail &quot;MySQL integration specs not run! Could not load do_mysql: #{e}&quot;
     end
   end
-end
\ No newline at end of file
+end</diff>
      <filename>spec/integration/mysql_adapter_spec.rb</filename>
    </modified>
    <modified>
      <diff>@@ -1,7 +1,7 @@
 require 'pathname'
 require Pathname(__FILE__).dirname.expand_path.parent + 'spec_helper'
 
-require __DIR__.parent.parent + 'lib/data_mapper'
+require ROOT_DIR + 'lib/data_mapper'
 
 begin
   require 'do_postgres'</diff>
      <filename>spec/integration/postgres_adapter_spec.rb</filename>
    </modified>
    <modified>
      <diff>@@ -8,11 +8,11 @@ begin
 
   describe DataMapper::Property do
     describe&quot; tracking strategies&quot; do
-    
+
       before do
         class Actor
           include DataMapper::Resource
-        
+
           property :id, Fixnum, :serial =&gt; true
           property :name, String, :lock =&gt; true
           property :notes, DataMapper::Types::Text, :track =&gt; false
@@ -23,7 +23,7 @@ begin
           property :agent, String, :track =&gt; :hash # :track only Object#hash value on :load.
             # Potentially faster, but less safe, so use judiciously, when the odds of a hash-collision are low.
         end
-      
+
         @adapter = DataMapper::Repository.adapters[:sqlite3] || DataMapper.setup(:sqlite3, &quot;sqlite3://#{__DIR__}/integration_test.db&quot;)
         @adapter.execute &lt;&lt;-EOS.compress_lines
           CREATE TABLE actors (
@@ -38,7 +38,7 @@ begin
           )
         EOS
       end
-    
+
       it &quot;false&quot; do
         pending(&quot;Implementation...&quot;)
         DataMapper::Resource::DIRTY.should_not be_nil
@@ -46,7 +46,7 @@ begin
         bob.original_attributes.should have_key(:name)
         bob.original_attributes[:name].should == DataMapper::Resource::DIRTY
       end
-    
+
       it &quot;:load&quot; do
         pending(&quot;Implementation...&quot;)
         DataMapper::Resource::DIRTY.should_not be_nil
@@ -54,7 +54,7 @@ begin
         bob.original_attributes.should have_key(:name)
         bob.original_attributes[:name].should == DataMapper::Resource::DIRTY
       end
-    
+
       it &quot;:hash&quot; do
         pending(&quot;Implementation...&quot;)
         DataMapper::Resource::DIRTY.should_not be_nil
@@ -62,7 +62,7 @@ begin
         bob.original_attributes.should have_key(:name)
         bob.original_attributes[:name].should == DataMapper::Resource::DIRTY
       end
-    
+
       it &quot;:get&quot; do
         pending(&quot;Implementation...&quot;)
         DataMapper::Resource::DIRTY.should_not be_nil
@@ -70,7 +70,7 @@ begin
         bob.original_attributes.should have_key(:name)
         bob.original_attributes[:name].should == DataMapper::Resource::DIRTY
       end
-    
+
       it &quot;:set&quot; do
         pending(&quot;Implementation...&quot;)
         DataMapper::Resource::DIRTY.should_not be_nil
@@ -78,12 +78,12 @@ begin
         bob.original_attributes.should have_key(:name)
         bob.original_attributes[:name].should == DataMapper::Resource::DIRTY
       end
-      
+
       after do
         @adapter.execute(&quot;DROP TABLE actors&quot;)
       end
     end
-    
+
     describe &quot;lazy loading&quot; do
       before do
         @adapter = DataMapper::Repository.adapters[:sqlite3] || DataMapper.setup(:sqlite3, &quot;sqlite3://#{__DIR__}/integration_test.db&quot;)
@@ -137,10 +137,10 @@ begin
        @adapter.execute('DROP TABLE &quot;sail_boats&quot;')
       end
 
-    end  
+    end
 
   end
-  
+
 rescue LoadError
   warn &quot;integration/property_spec not run! Could not load do_sqlite3.&quot;
 end</diff>
      <filename>spec/integration/property_spec.rb</filename>
    </modified>
    <modified>
      <diff>@@ -1,7 +1,7 @@
 require 'pathname'
 require Pathname(__FILE__).dirname.expand_path.parent + 'spec_helper'
 
-require __DIR__.parent.parent + 'lib/data_mapper'
+require ROOT_DIR + 'lib/data_mapper'
 
 begin
   require 'do_sqlite3'
@@ -261,29 +261,29 @@ begin
           DataMapper::Query.new(Vehicle,:links=&gt;[:sailing])
         }.should raise_error(ArgumentError)
       end
-  
+
       it 'should create an n-level query path' do
         Vehicle.factory.region.model.should == Region
         Vehicle.factory.region.name.property.should == Region.properties(Region.repository.name)[:name]
       end
-  
-      it 'should accept a DM::QueryPath as the key to a condition' do    
+
+      it 'should accept a DM::QueryPath as the key to a condition' do
         repository(:sqlite3) do
           vehicle = Vehicle.first(Vehicle.factory.region.name =&gt; 'North West')
           vehicle.name.should == '10 ton delivery truck'
-        end      
+        end
       end
-    
-    
-      it 'should auto generate the link if a DM::Property from a different resource is in the :fields option'      
+
+
+      it 'should auto generate the link if a DM::Property from a different resource is in the :fields option'
       it 'should create links with composite keys'
-      
-      
+
+
       it 'should eager load associations' do
         repository(:sqlite3) do
-          vehicle = Vehicle.first(:includes =&gt; [Vehicle.factory]) 
-        end    
-      end 
+          vehicle = Vehicle.first(:includes =&gt; [Vehicle.factory])
+        end
+      end
 
       after do
         @adapter.execute('DROP TABLE &quot;regions&quot;')</diff>
      <filename>spec/integration/query_spec.rb</filename>
    </modified>
    <modified>
      <diff>@@ -1,7 +1,7 @@
 require 'pathname'
 require Pathname(__FILE__).dirname.expand_path.parent + 'spec_helper'
 
-require __DIR__.parent.parent + 'lib/data_mapper'
+require ROOT_DIR + 'lib/data_mapper'
 
 
 begin
@@ -73,4 +73,4 @@ begin
   end
 rescue LoadError
   warn &quot;integration/repository_spec not run! Could not load do_sqlite3.&quot;
-end  
+end</diff>
      <filename>spec/integration/repository_spec.rb</filename>
    </modified>
    <modified>
      <diff>@@ -1,7 +1,7 @@
 require 'pathname'
 require Pathname(__FILE__).dirname.expand_path.parent + 'spec_helper'
 
-require __DIR__.parent.parent + 'lib/data_mapper'
+require ROOT_DIR + 'lib/data_mapper'
 
 begin
   require 'do_sqlite3'
@@ -221,7 +221,7 @@ begin
       after do
         @adapter.execute('DROP TABLE &quot;bank_customers&quot;')
       end
-    end  
+    end
   end
 rescue LoadError =&gt; e
   describe 'do_sqlite3' do</diff>
      <filename>spec/integration/sqlite3_adapter_spec.rb</filename>
    </modified>
    <modified>
      <diff>@@ -2,36 +2,35 @@ require 'pathname'
 require Pathname(__FILE__).dirname.expand_path.parent + 'spec_helper'
 require 'faster_csv'
 
-
 begin
   require 'do_sqlite3'
-    
+
   DataMapper.setup(:sqlite3, &quot;sqlite3://#{__DIR__}/integration_test.db&quot;) unless DataMapper::Repository.adapters[:sqlite3]
 
   describe DataMapper::Type do
 
     before do
-      
+
       @adapter = repository(:sqlite3).adapter
       @adapter.execute(&quot;CREATE TABLE coconuts (id INTEGER PRIMARY KEY, faked TEXT, document TEXT, stuff TEXT)&quot;)
-      
-      module TypeTests        
+
+      module TypeTests
         class Impostor &lt; DataMapper::Type
           primitive String
         end
-        
+
         class Coconut
           include DataMapper::Resource
-          
+
           resource_names[:sqlite3] = 'coconuts'
-          
+
           property :id, Fixnum, :serial =&gt; true
           property :faked, Impostor
           property :document, DM::Csv
           property :stuff, DM::Yaml
         end
       end
-      
+
       @document = &lt;&lt;-EOS.margin
         NAME, RATING, CONVENIENCE
         Freebird's, 3, 3
@@ -39,50 +38,50 @@ begin
         Jimmy John's, 3, 4
         Mignon, 5, 2
         Fuzi Yao's, 5, 1
-        Blue Goose, 5, 1 
+        Blue Goose, 5, 1
       EOS
-      
+
       @stuff = YAML::dump({ 'Happy Cow!' =&gt; true, 'Sad Cow!' =&gt; false })
     end
-    
+
     it &quot;should instantiate an object with custom types&quot; do
       coconut = TypeTests::Coconut.new(:faked =&gt; 'bob', :document =&gt; @document, :stuff =&gt; @stuff)
       coconut.faked.should == 'bob'
       coconut.document.should be_a_kind_of(Array)
       coconut.stuff.should be_a_kind_of(Hash)
     end
-    
+
     it &quot;should CRUD an object with custom types&quot; do
       repository(:sqlite3) do
         coconut = TypeTests::Coconut.new(:faked =&gt; 'bob', :document =&gt; @document, :stuff =&gt; @stuff)
         coconut.save.should be_true
         coconut.id.should_not be_nil
-      
+
         fred = TypeTests::Coconut[coconut.id]
         fred.faked.should == 'bob'
         fred.document.should be_a_kind_of(Array)
         fred.stuff.should be_a_kind_of(Hash)
 
         texadelphia = [&quot;Texadelphia&quot;, &quot;5&quot;, &quot;3&quot;]
-        
+
         # Figure out how to track these... possibly proxies? :-p
         document = fred.document.dup
         document &lt;&lt; texadelphia
         fred.document = document
-        
+
         stuff = fred.stuff.dup
         stuff['Manic Cow!'] = :maybe
         fred.stuff = stuff
-        
+
         fred.save.should be_true
-        
+
         # Can't call coconut.reload! since coconut.loaded_set isn't setup.
         mac = TypeTests::Coconut[fred.id]
         mac.document.last.should == texadelphia
         mac.stuff['Manic Cow!'].should == :maybe
       end
     end
-    
+
     after do
       @adapter = repository(:sqlite3).adapter
       @adapter.execute(&quot;DROP TABLE coconuts&quot;)
@@ -90,4 +89,4 @@ begin
   end
 rescue LoadError
   warn &quot;integration/type_spec not run! Could not load do_sqlite3.&quot;
-end    
+end</diff>
      <filename>spec/integration/type_spec.rb</filename>
    </modified>
    <modified>
      <diff>@@ -6,12 +6,12 @@ require 'spec'
 # for __DIR__
 require Pathname(__FILE__).dirname.expand_path.parent + 'lib/data_mapper/support/kernel'
 
-ENV['LOG_NAME'] = 'spec'
-require __DIR__.parent + 'environment'
-require __DIR__ + 'mock_adapter'
-
 ROOT_DIR = __DIR__.parent
 
+ENV['LOG_NAME'] = 'spec'
+require ROOT_DIR + 'environment'
+require __DIR__ + 'lib/mock_adapter'
+
 class Article
   include DataMapper::Resource
 
@@ -40,21 +40,21 @@ end
 # Used for Association specs
 class Vehicle
   include DataMapper::Resource
-  
+
   property :id, Fixnum, :serial =&gt; true
   property :name, String
 end
 
 class Manufacturer
   include DataMapper::Resource
-  
+
   property :id, Fixnum, :serial =&gt; true
   property :name, String
 end
 
 class Supplier
   include DataMapper::Resource
-  
+
   property :id, Fixnum, :serial =&gt; true
   property :name, String
 end</diff>
      <filename>spec/spec_helper.rb</filename>
    </modified>
  </modified>
  <removed type="array">
    <removed>
      <filename>spec/mock_adapter.rb</filename>
    </removed>
  </removed>
  <parents type="array">
    <parent>
      <id>81d2787c0e427c0e805d15be69190c80a8c21b2d</id>
    </parent>
  </parents>
  <author>
    <name>Dan Kubb</name>
    <email>dan.kubb@autopilotmarketing.com</email>
  </author>
  <url>http://github.com/wycats/dm-core/commit/cef28042782d6c0800ee5f568e184600d3fd64c5</url>
  <id>cef28042782d6c0800ee5f568e184600d3fd64c5</id>
  <committed-date>2008-04-10T00:20:49-07:00</committed-date>
  <authored-date>2008-04-10T00:20:49-07:00</authored-date>
  <message>Moved mock_adapter into spec/lib</message>
  <tree>b8b13abd416a6e5515c694c99eb2009980dd0181</tree>
  <committer>
    <name>Dan Kubb</name>
    <email>dan.kubb@autopilotmarketing.com</email>
  </committer>
</commit>
