<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -1,146 +1,173 @@
-= harvest
-
-A ruby library wrapping (most of) the Harvest Api.
-
-== DESCRIPTION:
-
-This library uses ActiveResource and activeresource_throttle to provide simple, reliable access to the Harvest Api.  Good for building reporting scripts and simple apps.
-
-Note that this library does not support the complete Harvest Api at this time. See Features/Issues below for details.
-
-== USAGE:
-
-=== Creating a new harvest object:
-
-All calls to the Harvest API will originate from a Harvest object. Initialize it like so:
-
-  @harvest = Harvest(:email      =&gt; &quot;joe@example.com&quot;, 
-                     :password   =&gt; &quot;secret&quot;, 
-                     :sub_domain =&gt; &quot;joeandcompany&quot;,
-                     :headers    =&gt; {&quot;User-Agent&quot; =&gt; &quot;MyCompany&quot;})
-                     
-The _headers_ argument is optional. Use &lt;b&gt;:ssl =&gt; true&lt;/b&gt; if your account requires HTTPS.
-                       
-=== Clients
-
-Index
-  @harvest.clients.find(:all)
-Show
-  @harvest.clients.find(43235)
-Create
-  @client = @harvest.clients.new
-  @client.attributes = {:name =&gt; &quot;Company, LLC&quot;, :details =&gt; &quot;New York, NY&quot;}
-  @client.save
-Update
-  @client.first_name = &quot;Smith&quot;
-  @client.save
-Destroy
-  @client.destroy
-
-Toggle (Active/Inactive)
-  @client.toggle
-  
-=== Tasks
-
-Index
-  @harvest.tasks.find(:all)
-Show
-  @harvest.tasks.find(123)
-Create
-  @task = @harvest.tasks.new
-  @task.attributes = {:name =&gt; &quot;Meeting&quot;,   :billable_by_default =&gt; false,
-                      :is_default =&gt; false, :default_hourly_rate =&gt; 100}
-  @task.save
-Update
-  @task.name = &quot;Client Meeting&quot;
-  @task.save
-Destroy
-  @task.destroy
-  
-=== People
-
-Index
-  @harvest.people.find(:all)
-Show
-  @harvest.people.find(123)
-  
-=== Projects
-
-Index
-  @harvest.projects.find(:all)
-Show
-  @harvest.projects.find(123)
-Create
-  @project = @harvest.projects.new
-  @project.attributes = {:name =&gt; &quot;Refactor&quot;, :active =&gt; true, 
-                         :bill_by =&gt; &quot;None&quot;, :client_id =&gt; @client.id, }
-  @project.save
-Update
-  @project.name = &quot;Mega-Refactor&quot;
-  @project.save
-Destroy
-  @project.destroy
-
-Toggle (Active/Inactive)
-  @project.toggle
-    
-==== User and Task Assignments
-
-  @project.users.find(:all)
-  @project.users.find(:first)
-  
-  @project.tasks.find(:all)
-  @project.tasks.find(:first)
-  
-=== Reports
-
-  @project.entries(:from =&gt; Time.now, :to =&gt; Time.now)
-  @project.entries(:from =&gt; Time.now, :to =&gt; Time.now, :user_id =&gt; @person.id)
-  
-  @person.entries(:from =&gt; Time.now, :to =&gt; Time.now)
-  @person.expenses(:from =&gt; Time.now, :to =&gt; Time.now)
-  
-== FEATURES/PROBLEMS:
-
-Supports most of the Harvest Api (http://www.getharvest.com/api).
-
-Though RESTful, the Harvest Api does not entirely follow ActiveResource conventions. In order to support the complete API, certain customizations will be required. &lt;b&gt;We welcome any contributions/modifications to help complete this Api.&lt;/b&gt;
-
-The following Api features are incomplete due to incompatibilities with ActiveResource conventions (CRUD actions in parentheses):
-
-1. People (CUD)
-2. User &amp; Task Assignments (CUD)
-3. Expenses (CUD)
-
-In addition, the following have not been implemented at all due to time constraints:
-
-1. Time Tracking Api
-2. Invoices, Invoice Payments, Invoice Categories, and Invoice Messages 
-
-Expect a more complete library in the near future. Again, contributions are welcome.
-
-== TEST SUITE
-
-This library includes a fairly thorough set of unit and integration tests. The unit tests can be run with the &quot;rake&quot; command.
-
-The integration tests require a Harvest account. It is best to use a trial account when running these tests.
-
-The credentials may be entered in test/test_helper.rb. To run the integration suite:
-
-  rake test:integration
-  
-Note that the integration test structure is somewhat unorthodox, as it requires tests to run in a particular order. The main test file is test/integration/harvest_integration_test.rb. Examine this to see how the integration suite works.
-  
-== REQUIREMENTS:
-
-Requires active_resource &gt;= 2.1 and activeresource_throttle &gt;= 1.0.
-
-active_resource_throttle should install automaticallt, but just in case you need to install manually:
-
-  gem sources -a http://gems.github.com
-  sudo gem install aiaio-active_resource_throttle 
-
-== INSTALL:
-  
-  gem sources -a http://gems.github.com
-  gem install aiaio-harvest
+= harvest
+
+A ruby library wrapping (most of) the Harvest Api.
+
+== DESCRIPTION:
+
+This library uses ActiveResource and activeresource_throttle to provide simple, reliable access to the Harvest Api.  Good for building reporting scripts and simple apps.
+
+Note that this library does not support the complete Harvest Api at this time. See Features/Issues below for details.
+
+== USAGE:
+
+=== Creating a new harvest object:
+
+All calls to the Harvest API will originate from a Harvest object. Initialize it like so:
+
+  @harvest = Harvest(:email      =&gt; &quot;joe@example.com&quot;, 
+                     :password   =&gt; &quot;secret&quot;, 
+                     :sub_domain =&gt; &quot;joeandcompany&quot;,
+                     :headers    =&gt; {&quot;User-Agent&quot; =&gt; &quot;MyCompany&quot;})
+                     
+The _headers_ argument is optional. Use &lt;b&gt;:ssl =&gt; true&lt;/b&gt; if your account requires HTTPS.
+                       
+=== Clients
+
+Index
+  @harvest.clients.find(:all)
+Show
+  @harvest.clients.find(43235)
+Create
+  @client = @harvest.clients.new
+  @client.attributes = {:name =&gt; &quot;Company, LLC&quot;, :details =&gt; &quot;New York, NY&quot;}
+  @client.save
+Update
+  @client.first_name = &quot;Smith&quot;
+  @client.save
+Destroy
+  @client.destroy
+
+Toggle (Active/Inactive)
+  @client.toggle
+  
+=== Tasks
+
+Index
+  @harvest.tasks.find(:all)
+Show
+  @harvest.tasks.find(123)
+Create
+  @task = @harvest.tasks.new
+  @task.attributes = {:name =&gt; &quot;Meeting&quot;,   :billable_by_default =&gt; false,
+                      :is_default =&gt; false, :default_hourly_rate =&gt; 100}
+  @task.save
+Update
+  @task.name = &quot;Client Meeting&quot;
+  @task.save
+Destroy
+  @task.destroy
+  
+=== People
+
+Index
+  @harvest.people.find(:all)
+Show
+  @harvest.people.find(123)
+  
+=== Projects
+
+Index
+  @harvest.projects.find(:all)
+Show
+  @harvest.projects.find(123)
+Create
+  @project = @harvest.projects.new
+  @project.attributes = {:name =&gt; &quot;Refactor&quot;, :active =&gt; true, 
+                         :bill_by =&gt; &quot;None&quot;, :client_id =&gt; @client.id, }
+  @project.save
+Update
+  @project.name = &quot;Mega-Refactor&quot;
+  @project.save
+Destroy
+  @project.destroy
+
+Toggle (Active/Inactive)
+  @project.toggle
+
+=== Invoices
+
+Index
+  @invoices = @harvest.invoices.find(:all)
+
+Show
+  @invoice = @harvest.invoices.find(1)
+
+Find By Invoice Number
+  @invoice = @harvest.invoices.find_by_number('200')
+
+Create
+  @invoice = @harvest.invoices.new
+  @invoice.attributes = {:amount =&gt; '250.32', :client_id =&gt; @client.id}
+  @invoice.save
+
+Update
+  @invoice.notes = &quot;Pending payment&quot;
+  @invoice.save
+
+Destroy
+  @invoice.destroy
+
+Return parsed csv line items
+  @invoice.parsed_csv_line_items
+ 
+==== User and Task Assignments
+
+  @project.users.find(:all)
+  @project.users.find(:first)
+  
+  @project.tasks.find(:all)
+  @project.tasks.find(:first)
+  
+=== Reports
+
+  @project.entries(:from =&gt; Time.now, :to =&gt; Time.now)
+  @project.entries(:from =&gt; Time.now, :to =&gt; Time.now, :user_id =&gt; @person.id)
+  
+  @person.entries(:from =&gt; Time.now, :to =&gt; Time.now)
+  @person.expenses(:from =&gt; Time.now, :to =&gt; Time.now)
+
+ 
+== FEATURES/PROBLEMS:
+
+Supports most of the Harvest Api (http://www.getharvest.com/api).
+
+Though RESTful, the Harvest Api does not entirely follow ActiveResource conventions. In order to support the complete API, certain customizations will be required. &lt;b&gt;We welcome any contributions/modifications to help complete this Api.&lt;/b&gt;
+
+The following Api features are incomplete due to incompatibilities with ActiveResource conventions (CRUD actions in parentheses):
+
+1. People (CUD)
+2. User &amp; Task Assignments (CUD)
+3. Expenses (CUD)
+
+In addition, the following have not been implemented at all due to time constraints:
+
+1. Time Tracking Api
+2. Invoices, Invoice Payments, Invoice Categories, and Invoice Messages 
+
+Expect a more complete library in the near future. Again, contributions are welcome.
+
+== TEST SUITE
+
+This library includes a fairly thorough set of unit and integration tests. The unit tests can be run with the &quot;rake&quot; command.
+
+The integration tests require a Harvest account. It is best to use a trial account when running these tests.
+
+The credentials may be entered in test/test_helper.rb. To run the integration suite:
+
+  rake test:integration
+  
+Note that the integration test structure is somewhat unorthodox, as it requires tests to run in a particular order. The main test file is test/integration/harvest_integration_test.rb. Examine this to see how the integration suite works.
+  
+== REQUIREMENTS:
+
+Requires active_resource &gt;= 2.1 and activeresource_throttle &gt;= 1.0.
+
+active_resource_throttle should install automaticallt, but just in case you need to install manually:
+
+  gem sources -a http://gems.github.com
+  sudo gem install aiaio-active_resource_throttle 
+
+== INSTALL:
+  
+  gem sources -a http://gems.github.com
+  gem install aiaio-harvest</diff>
      <filename>README.rdoc</filename>
    </modified>
    <modified>
      <diff>@@ -2,7 +2,7 @@
  
  Gem::Specification.new do |s|
   s.name        = &quot;harvest&quot;
-  s.version     = &quot;0.8.1&quot;
+  s.version     = &quot;0.8.2&quot;
   s.authors     = [&quot;Kyle Banker&quot;, &quot;Alexander Interactive, Inc.&quot;]
   s.date        = &quot;2008-12-17&quot;
   s.summary     = &quot;A wrapper for the Harvest Api.  See http://getharvest.com/api for details.&quot;</diff>
      <filename>harvest.gemspec</filename>
    </modified>
    <modified>
      <diff>@@ -36,16 +36,16 @@ class InvoiceTest &lt; Test::Unit::TestCase
     end
 
     should &quot;create a new invoice&quot; do
-      project = Harvest::Resources::Invoice.new(:number =&gt; &quot;200&quot;)
-      project.save
+      invoice = Harvest::Resources::Invoice.new(:number =&gt; &quot;200&quot;)
+      invoice.save
       expected_request = ActiveResource::Request.new(:post, &quot;/invoices.xml&quot;)
       assert ActiveResource::HttpMock.requests.include?(expected_request)
     end
 
     should &quot;update an existing invoice&quot; do
-      project = Harvest::Resources::Invoice.find(1)
-      project.number = &quot;200&quot;
-      project.save
+      invoice = Harvest::Resources::Invoice.find(1)
+      invoice.number = &quot;200&quot;
+      invoice.save
       expected_request = ActiveResource::Request.new(:put, &quot;/invoices/1.xml&quot;)
       assert ActiveResource::HttpMock.requests.include?(expected_request)
     end</diff>
      <filename>test/unit/resources/invoice_test.rb</filename>
    </modified>
    <modified>
      <diff>@@ -1,151 +1,150 @@
-require File.join(File.dirname(__FILE__), &quot;..&quot;, &quot;..&quot;, &quot;test_helper&quot;)
-
-class PersonTest &lt; Test::Unit::TestCase
-  
-  def setup_resources
-    @person_xml  =  {:id =&gt; 1, :name =&gt; &quot;Joe Coder&quot;}.to_xml(:root =&gt; &quot;person&quot;)
-    @people      = [{:id =&gt; 1, :name =&gt; &quot;Joe Coder&quot;}].to_xml(:root =&gt; &quot;people&quot;)
-    @entry       = [{:id =&gt; 2, :project_id =&gt; 50}].to_xml(:root =&gt; &quot;day-entries&quot;)
-    @entries     = [{:id =&gt; 1, :project_id =&gt; &quot;25&quot;}, 
-                    {:id =&gt; 2, :project_id =&gt; 50}  ].to_xml(:root =&gt; &quot;day-entries&quot;)
-    @expenses    = [{:id =&gt; 1, :project_id =&gt; &quot;25&quot;}, 
-                    {:id =&gt; 2, :project_id =&gt; 50}  ].to_xml(:root =&gt; &quot;expenses&quot;)
-  end
-  
-  def mock_responses
-    ActiveResource::HttpMock.respond_to do |mock|
-      mock.get    &quot;/people.xml&quot;,           {}, @people
-      mock.get    &quot;/people/1.xml&quot;,         {}, @person_xml
-      mock.post   &quot;/people.xml&quot;,           {}, @person_xml, 201, &quot;Location&quot; =&gt; &quot;/people/5.xml&quot;
-      mock.put    &quot;/people/1.xml&quot;,         {}, nil,     200
-      mock.delete &quot;/people/1.xml&quot;,         {}, nil,     200
-      mock.put    &quot;/people/1/toggle.xml&quot;,  {}, nil, 200
-      mock.get    &quot;/people/1/entries.xml?from=20080101&amp;to=20080131&quot;, {}, @entries
-      mock.get    &quot;/people/1/entries.xml?from=20080101&amp;project_id=3&amp;to=20080131&quot;, {}, @entry
-      mock.get    &quot;/people/1/expenses.xml?from=20080101&amp;to=20080131&quot;, {}, @expenses
-    end
-  end
-  
-  context &quot;People CRUD actions -- &quot; do 
-    setup do 
-      setup_resources
-      mock_responses
-    end
-    
-    should &quot;get index&quot; do 
-      Harvest::Resources::Person.find(:all)
-      expected_request = ActiveResource::Request.new(:get, &quot;/people.xml&quot;)
-      assert ActiveResource::HttpMock.requests.include?(expected_request)
-    end
-    
-    should &quot;get a single project&quot; do 
-      Harvest::Resources::Person.find(1)
-      expected_request = ActiveResource::Request.new(:get, &quot;/people/1.xml&quot;)
-      assert ActiveResource::HttpMock.requests.include?(expected_request)
-    end
-    
-    should &quot;create a new project&quot; do 
-      project = Harvest::Resources::Person.new(:name =&gt; &quot;Widgets&amp;Co&quot;)
-      project.save
-      expected_request = ActiveResource::Request.new(:post, &quot;/people.xml&quot;)
-      assert ActiveResource::HttpMock.requests.include?(expected_request)
-    end
-    
-    should &quot;update an existing project&quot; do 
-      project = Harvest::Resources::Person.find(1)
-      project.name = &quot;Joe Coder&quot;
-      project.save
-      expected_request = ActiveResource::Request.new(:put, &quot;/people/1.xml&quot;)
-      assert ActiveResource::HttpMock.requests.include?(expected_request)
-    end
-    
-    should &quot;delete an existing project&quot; do 
-      Harvest::Resources::Person.delete(1)
-      expected_request = ActiveResource::Request.new(:delete, &quot;/people/1.xml&quot;)
-      assert ActiveResource::HttpMock.requests.include?(expected_request)
-    end
-    
-  end
-  
-    
-  context &quot;Toggling active/inactive status&quot; do 
-    setup do 
-      setup_resources
-      mock_responses
-    end
-    
-    should &quot;hit the toggle method&quot; do
-      person = Harvest::Resources::Person.find(1)
-      person.toggle
-      expected_request = ActiveResource::Request.new(:put, &quot;/people/1/toggle.xml&quot;)
-      assert ActiveResource::HttpMock.requests.include?(expected_request)
-    end
-    
-    should &quot;return 200 Success toggle method&quot; do
-      person = Harvest::Resources::Person.find(1)
-      assert person.toggle.code == 200
-    end
-        
-  end
-  
-  context &quot;Getting entries&quot; do 
-    setup do 
-      setup_resources
-      mock_responses
-      @person = Harvest::Resources::Person.find(1)
-    end
-    
-    should &quot;raise an error if start and end are not included&quot; do 
-      assert_raises ArgumentError, &quot;Must specify :start and :end as dates.&quot; do  
-        @person.entries
-      end
-    end
-    
-    should &quot;raise an error if end date precedes start date&quot; do 
-      assert_raises ArgumentError, &quot;Must specify :start and :end as dates.&quot; do  
-        @person.entries(:from =&gt; Time.utc(2007, 1, 1), :to =&gt; Time.utc(2006, 1, 1))
-      end
-    end
-    
-    should &quot;return the project site prefix&quot; do
-      entry_class = Harvest::Resources::Entry.clone
-      entry_class.person_id = @person.id
-      assert_equal &quot;http://example.com/people/1&quot;, entry_class.site.to_s
-    end
-    
-  end
-  
-  context &quot;Reports -- &quot; do   
-    setup do
-      setup_resources 
-      mock_responses
-      @from    = Time.utc(2008, 1, 1)
-      @to      = Time.utc(2008, 1, 31)
-      @person = Harvest::Resources::Person.find(1)
-      @request_path = &quot;/people/1/entries.xml?from=20080101&amp;to=20080131&quot;
-      @expense_path = &quot;/people/1/expenses.xml?from=20080101&amp;to=20080131&quot;
-    end
-      
-    should &quot;get all entries for a given date range&quot; do
-      @person.entries(:from =&gt; @from, :to =&gt; @to)
-      expected_request = ActiveResource::Request.new(:get, @request_path)
-      assert ActiveResource::HttpMock.requests.include?(expected_request)
-    end
-    
-    should &quot;get all entries for the given date range and user&quot; do 
-      path = &quot;/people/1/entries.xml?from=20080101&amp;project_id=3&amp;to=20080131&quot;
-      @person.entries(:from =&gt; @from, :to =&gt; @to, :project_id =&gt; 3)
-      expected_request = ActiveResource::Request.new(:get, path)
-      assert ActiveResource::HttpMock.requests.include?(expected_request)
-    end
-    
-    should &quot;return all expense entries logged by the given user&quot; do
-      @person.expenses(:from =&gt; @from, :to =&gt; @to)
-      expected_request = ActiveResource::Request.new(:get, @expense_path)
-      p ActiveResource::HttpMock.requests
-      assert ActiveResource::HttpMock.requests.include?(expected_request)
-    end
-       
-  end
-      
-end
\ No newline at end of file
+require File.join(File.dirname(__FILE__), &quot;..&quot;, &quot;..&quot;, &quot;test_helper&quot;)
+
+class PersonTest &lt; Test::Unit::TestCase
+  
+  def setup_resources
+    @person_xml  =  {:id =&gt; 1, :name =&gt; &quot;Joe Coder&quot;}.to_xml(:root =&gt; &quot;person&quot;)
+    @people      = [{:id =&gt; 1, :name =&gt; &quot;Joe Coder&quot;}].to_xml(:root =&gt; &quot;people&quot;)
+    @entry       = [{:id =&gt; 2, :project_id =&gt; 50}].to_xml(:root =&gt; &quot;day-entries&quot;)
+    @entries     = [{:id =&gt; 1, :project_id =&gt; &quot;25&quot;}, 
+                    {:id =&gt; 2, :project_id =&gt; 50}  ].to_xml(:root =&gt; &quot;day-entries&quot;)
+    @expenses    = [{:id =&gt; 1, :project_id =&gt; &quot;25&quot;}, 
+                    {:id =&gt; 2, :project_id =&gt; 50}  ].to_xml(:root =&gt; &quot;expenses&quot;)
+  end
+  
+  def mock_responses
+    ActiveResource::HttpMock.respond_to do |mock|
+      mock.get    &quot;/people.xml&quot;,           {}, @people
+      mock.get    &quot;/people/1.xml&quot;,         {}, @person_xml
+      mock.post   &quot;/people.xml&quot;,           {}, @person_xml, 201, &quot;Location&quot; =&gt; &quot;/people/5.xml&quot;
+      mock.put    &quot;/people/1.xml&quot;,         {}, nil,     200
+      mock.delete &quot;/people/1.xml&quot;,         {}, nil,     200
+      mock.put    &quot;/people/1/toggle.xml&quot;,  {}, nil, 200
+      mock.get    &quot;/people/1/entries.xml?from=20080101&amp;to=20080131&quot;, {}, @entries
+      mock.get    &quot;/people/1/entries.xml?from=20080101&amp;project_id=3&amp;to=20080131&quot;, {}, @entry
+      mock.get    &quot;/people/1/expenses.xml?from=20080101&amp;to=20080131&quot;, {}, @expenses
+    end
+  end
+  
+  context &quot;People CRUD actions -- &quot; do 
+    setup do 
+      setup_resources
+      mock_responses
+    end
+    
+    should &quot;get index&quot; do 
+      Harvest::Resources::Person.find(:all)
+      expected_request = ActiveResource::Request.new(:get, &quot;/people.xml&quot;)
+      assert ActiveResource::HttpMock.requests.include?(expected_request)
+    end
+    
+    should &quot;get a single project&quot; do 
+      Harvest::Resources::Person.find(1)
+      expected_request = ActiveResource::Request.new(:get, &quot;/people/1.xml&quot;)
+      assert ActiveResource::HttpMock.requests.include?(expected_request)
+    end
+    
+    should &quot;create a new project&quot; do 
+      project = Harvest::Resources::Person.new(:name =&gt; &quot;Widgets&amp;Co&quot;)
+      project.save
+      expected_request = ActiveResource::Request.new(:post, &quot;/people.xml&quot;)
+      assert ActiveResource::HttpMock.requests.include?(expected_request)
+    end
+    
+    should &quot;update an existing project&quot; do 
+      project = Harvest::Resources::Person.find(1)
+      project.name = &quot;Joe Coder&quot;
+      project.save
+      expected_request = ActiveResource::Request.new(:put, &quot;/people/1.xml&quot;)
+      assert ActiveResource::HttpMock.requests.include?(expected_request)
+    end
+    
+    should &quot;delete an existing project&quot; do 
+      Harvest::Resources::Person.delete(1)
+      expected_request = ActiveResource::Request.new(:delete, &quot;/people/1.xml&quot;)
+      assert ActiveResource::HttpMock.requests.include?(expected_request)
+    end
+    
+  end
+  
+    
+  context &quot;Toggling active/inactive status&quot; do 
+    setup do 
+      setup_resources
+      mock_responses
+    end
+    
+    should &quot;hit the toggle method&quot; do
+      person = Harvest::Resources::Person.find(1)
+      person.toggle
+      expected_request = ActiveResource::Request.new(:put, &quot;/people/1/toggle.xml&quot;)
+      assert ActiveResource::HttpMock.requests.include?(expected_request)
+    end
+    
+    should &quot;return 200 Success toggle method&quot; do
+      person = Harvest::Resources::Person.find(1)
+      assert person.toggle.code == 200
+    end
+        
+  end
+  
+  context &quot;Getting entries&quot; do 
+    setup do 
+      setup_resources
+      mock_responses
+      @person = Harvest::Resources::Person.find(1)
+    end
+    
+    should &quot;raise an error if start and end are not included&quot; do 
+      assert_raises ArgumentError, &quot;Must specify :start and :end as dates.&quot; do  
+        @person.entries
+      end
+    end
+    
+    should &quot;raise an error if end date precedes start date&quot; do 
+      assert_raises ArgumentError, &quot;Must specify :start and :end as dates.&quot; do  
+        @person.entries(:from =&gt; Time.utc(2007, 1, 1), :to =&gt; Time.utc(2006, 1, 1))
+      end
+    end
+    
+    should &quot;return the project site prefix&quot; do
+      entry_class = Harvest::Resources::Entry.clone
+      entry_class.person_id = @person.id
+      assert_equal &quot;http://example.com/people/1&quot;, entry_class.site.to_s
+    end
+    
+  end
+  
+  context &quot;Reports -- &quot; do   
+    setup do
+      setup_resources 
+      mock_responses
+      @from    = Time.utc(2008, 1, 1)
+      @to      = Time.utc(2008, 1, 31)
+      @person = Harvest::Resources::Person.find(1)
+      @request_path = &quot;/people/1/entries.xml?from=20080101&amp;to=20080131&quot;
+      @expense_path = &quot;/people/1/expenses.xml?from=20080101&amp;to=20080131&quot;
+    end
+      
+    should &quot;get all entries for a given date range&quot; do
+      @person.entries(:from =&gt; @from, :to =&gt; @to)
+      expected_request = ActiveResource::Request.new(:get, @request_path)
+      assert ActiveResource::HttpMock.requests.include?(expected_request)
+    end
+    
+    should &quot;get all entries for the given date range and user&quot; do 
+      path = &quot;/people/1/entries.xml?from=20080101&amp;project_id=3&amp;to=20080131&quot;
+      @person.entries(:from =&gt; @from, :to =&gt; @to, :project_id =&gt; 3)
+      expected_request = ActiveResource::Request.new(:get, path)
+      assert ActiveResource::HttpMock.requests.include?(expected_request)
+    end
+    
+    should &quot;return all expense entries logged by the given user&quot; do
+      @person.expenses(:from =&gt; @from, :to =&gt; @to)
+      expected_request = ActiveResource::Request.new(:get, @expense_path)
+      assert ActiveResource::HttpMock.requests.include?(expected_request)
+    end
+       
+  end
+      
+end</diff>
      <filename>test/unit/resources/person_test.rb</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>ab5fe9ce3b3fbb92f797f39752fd88b59ac342d1</id>
    </parent>
  </parents>
  <author>
    <name>aiaio</name>
    <email>knb@alexanderinteractive.com</email>
  </author>
  <url>http://github.com/aiaio/harvest/commit/485940b1205549c8bea1e0a9c5175c2a51ad7282</url>
  <id>485940b1205549c8bea1e0a9c5175c2a51ad7282</id>
  <committed-date>2009-06-08T10:11:54-07:00</committed-date>
  <authored-date>2009-06-08T10:11:54-07:00</authored-date>
  <message>Fixes for invoice support.</message>
  <tree>51f135a3067b9efeec795ac490f0e8f086e9b7fd</tree>
  <committer>
    <name>aiaio</name>
    <email>knb@alexanderinteractive.com</email>
  </committer>
</commit>
