title: Trouble comparing time with RSpec
body: <p>I am using Ruby on Rails 4 and the rspec-rails gem 2.14. For a my object I would like to compare the current time with the <code>updated_at</code> object attribute after a controller action run, but I am in trouble since the spec does not pass. That is, given the following is the spec code:</p>
  
  <pre><code>it "updates updated_at attribute" do
    Timecop.freeze
  
    patch :update
    @article.reload
    expect(@article.updated_at).to eq(Time.now)
  end
  </code></pre>
  
  <p>When I run the above spec I get the following error:</p>
  
  <pre><code>Failure/Error: expect(@article.updated_at).to eq(Time.now)
  
     expected: 2013-12-05 14:42:20 UTC
          got: Thu, 05 Dec 2013 08:42:20 CST -06:00
  
     (compared using ==)
  </code></pre>
  
  <p>How can I make the spec to pass?</p>
  
  <hr>
  
  <p><em>Note</em>: I tried also the following (note the <code>utc</code> addition):</p>
  
  <pre><code>it "updates updated_at attribute" do
    Timecop.freeze
  
    patch :update
    @article.reload
    expect(@article.updated_at.utc).to eq(Time.now)
  end
  </code></pre>
  
  <p>but the spec still does not pass (note the "got" value difference):</p>
  
  <pre><code>Failure/Error: expect(@article.updated_at.utc).to eq(Time.now)
  
     expected: 2013-12-05 14:42:20 UTC
          got: 2013-12-05 14:42:20 UTC
  
     (compared using ==)
  </code></pre>