          ).order_by('name')
          self.assertQuerysetEqual(over_estimate, ['e3', 'e4', 'e5'], lambda e: e.name)
  
      def test_date_minus_duration(self):
          more_than_4_days = Experiment.objects.filter(
              assigned__lt=F('completed') - Value(datetime.timedelta(days=4), output_field=models.DurationField())
          )
          self.assertQuerysetEqual(more_than_4_days, ['e3', 'e4', 'e5'], lambda e: e.name)
 
</s> remove     return (left - right).total_seconds() * 1000000
 </s> add     return duration_microseconds(left - right) </s> remove         duration = datetime.timedelta(days=123, seconds=123, microseconds=123)
 </s> add         duration = datetime.timedelta(microseconds=8999999999999999) </s> remove         # Discard any fractional microseconds due to floating point arithmetic.
        return round(value.total_seconds() * 1000000)
 </s> add         return duration_microseconds(value)
    def test_duration_with_datetime_microseconds(self):
        delta = datetime.timedelta(microseconds=8999999999999999)
        qs = Experiment.objects.annotate(dt=ExpressionWrapper(
            F('start') + delta,
            output_field=models.DateTimeField(),
        ))
        for e in qs:
            self.assertEqual(e.dt, e.start + delta)

          ).order_by('name')
          self.assertQuerysetEqual(over_estimate, ['e3', 'e4', 'e5'], lambda e: e.name)
  
    def test_duration_with_datetime_microseconds(self):
        delta = datetime.timedelta(microseconds=8999999999999999)
        qs = Experiment.objects.annotate(dt=ExpressionWrapper(
            F('start') + delta,
            output_field=models.DateTimeField(),
        ))
        for e in qs:
            self.assertEqual(e.dt, e.start + delta)

      def test_date_minus_duration(self):
          more_than_4_days = Experiment.objects.filter(
              assigned__lt=F('completed') - Value(datetime.timedelta(days=4), output_field=models.DurationField())
          )
          self.assertQuerysetEqual(more_than_4_days, ['e3', 'e4', 'e5'], lambda e: e.name)
keep keep add keep keep keep keep keep
 Fixed #28926 -- Fixed loss of precision of big DurationField values on SQLite and MySQL. 
tests/expressions/tests.py