title: Compare two dates in python and ignoring microseconds
body: <p>I am inserting a date_added date time value into mysql 5.5 which does not support datetime(6) and this is causing an AssertionError when running the following unit test</p>
  
  <pre><code>foo.date_added = timezone.now()
  
  self.assertEquals(only_foo_in_database.date_added, foo.date_added)
  </code></pre>
  
  <p>which leads to</p>
  
  <pre><code>AssertionError: datetime.datetime(2013, 9, 2, 6, 48, 56, tzinfo=&lt;UTC&gt;) != datetime.datetime(2013, 9, 2, 6, 48, 56, 677255, tzinfo=&lt;UTC&gt;)
  </code></pre>
  
  <p>How can I compare the two datetime values ignoring the microseconds?</p>