Removed some uses of F() expression & and |

Refs #16211
This commit is contained in:
Anssi Kääriäinen 2012-10-10 03:28:48 +03:00
parent f578ee32fa
commit 041ef9ed68
1 changed files with 2 additions and 2 deletions

View File

@ -371,7 +371,7 @@ class FTimeDeltaTests(TestCase):
def test_delta_invalid_op_and(self):
raised = False
try:
r = repr(Experiment.objects.filter(end__lt=F('start')&self.deltas[0]))
r = repr(Experiment.objects.filter(end__lt=F('start').bitand(self.deltas[0])))
except TypeError:
raised = True
self.assertTrue(raised, "TypeError not raised on attempt to binary and a datetime with a timedelta.")
@ -379,7 +379,7 @@ class FTimeDeltaTests(TestCase):
def test_delta_invalid_op_or(self):
raised = False
try:
r = repr(Experiment.objects.filter(end__lt=F('start')|self.deltas[0]))
r = repr(Experiment.objects.filter(end__lt=F('start').bitor(self.deltas[0])))
except TypeError:
raised = True
self.assertTrue(raised, "TypeError not raised on attempt to binary or a datetime with a timedelta.")